Skip to content

Commit

Permalink
#1374 Fix admin role during migration
Browse files Browse the repository at this point in the history
  • Loading branch information
To-om committed Jun 29, 2020
1 parent 3a56149 commit 3416052
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,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.analyst.name)
Map(Organisation.administration.name -> Profile.admin.name, 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 3416052

Please sign in to comment.