Skip to content

Commit

Permalink
fixes #2554
Browse files Browse the repository at this point in the history
  • Loading branch information
nathandunn committed Feb 3, 2021
1 parent 93bd09e commit cc7babf
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
1 change: 1 addition & 0 deletions ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Features

Bug Fixes:
- Bad coordinate value in genomic element details screen in annotator panel [2559](https://github.com/GMOD/Apollo/issues/2559).
- Web services indicated user had no organism permissions when checking the login [2554](https://github.com/GMOD/Apollo/issues/2554).

Infrastructure Changes

Expand Down
7 changes: 5 additions & 2 deletions grails-app/controllers/org/bbop/apollo/UserController.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -257,9 +257,12 @@ class UserController {

def userObject = userService.convertUserToJson(currentUser)

if ((!userOrganismPreference || !permissionService.hasAnyPermissions(currentUser)) && !permissionService.isUserBetterOrEqualRank(currentUser, GlobalPermissionEnum.INSTRUCTOR)) {
// if lacks permissions and is not an instructor then there are no organisms to share
if (!permissionService.hasAnyPermissions(currentUser) && !permissionService.isUserBetterOrEqualRank(currentUser, GlobalPermissionEnum.INSTRUCTOR)) {
userObject.put(FeatureStringEnum.ERROR.value, "You do not have access to any organism on this server. Please contact your administrator.")
} else if (userOrganismPreference) {
}

if (userOrganismPreference) {
userObject.put("tracklist", userOrganismPreference.nativeTrackList)
}

Expand Down

0 comments on commit cc7babf

Please sign in to comment.