Skip to content

Commit

Permalink
#1645 Don't add admin users from TH3 to admin organisation
Browse files Browse the repository at this point in the history
  • Loading branch information
To-om committed Nov 12, 2020
1 parent 98180ee commit 1a48dbb
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -263,8 +263,7 @@ trait Conversion {
password <- (json \ "password").validateOpt[String]
role <- (json \ "roles").validateOpt[Seq[String]].map(_.getOrElse(Nil))
organisationProfiles =
if (role.contains("admin"))
Map(Organisation.administration.name -> Profile.admin.name, mainOrganisation -> Profile.orgAdmin.name)
if (role.contains("admin")) Map(mainOrganisation -> Profile.orgAdmin.name)
else if (role.contains("write")) Map(mainOrganisation -> Profile.analyst.name)
else if (role.contains("read")) Map(mainOrganisation -> Profile.readonly.name)
else Map(mainOrganisation -> Profile.readonly.name)
Expand Down

0 comments on commit 1a48dbb

Please sign in to comment.