diff options
author | jcardus <asklocation.net@gmail.com> | 2021-07-08 02:25:31 +0100 |
---|---|---|
committer | jcardus <asklocation.net@gmail.com> | 2021-07-08 02:25:31 +0100 |
commit | 44e9726886ad14c1b61e4dedb0acc97e7d76b46f (patch) | |
tree | a773d2e09727f3cd44c733bad483f882b449e935 /src/main/java/org/traccar | |
parent | 410c29d25c459a825f4349be7b12342105bcbd3e (diff) | |
download | traccar-server-44e9726886ad14c1b61e4dedb0acc97e7d76b46f.tar.gz traccar-server-44e9726886ad14c1b61e4dedb0acc97e7d76b46f.tar.bz2 traccar-server-44e9726886ad14c1b61e4dedb0acc97e7d76b46f.zip |
fix style
Diffstat (limited to 'src/main/java/org/traccar')
-rw-r--r-- | src/main/java/org/traccar/api/resource/PermissionsResource.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/main/java/org/traccar/api/resource/PermissionsResource.java b/src/main/java/org/traccar/api/resource/PermissionsResource.java index 32cf4faff..7502e9134 100644 --- a/src/main/java/org/traccar/api/resource/PermissionsResource.java +++ b/src/main/java/org/traccar/api/resource/PermissionsResource.java @@ -77,8 +77,9 @@ public class PermissionsResource extends BaseResource { permission.getPropertyClass(), permission.getPropertyId()); } // we assume all permissions are of same type so we use the first one for refreshing - if (!entities.isEmpty()) + if (!entities.isEmpty()) { Context.getPermissionsManager().refreshPermissions(new Permission(entities.get(0))); + } return Response.noContent().build(); } @@ -101,8 +102,9 @@ public class PermissionsResource extends BaseResource { LogAction.unlink(getUserId(), permission.getOwnerClass(), permission.getOwnerId(), permission.getPropertyClass(), permission.getPropertyId()); } - if (!entities.isEmpty()) + if (!entities.isEmpty()) { Context.getPermissionsManager().refreshPermissions(new Permission(entities.get(0))); + } return Response.noContent().build(); } |