aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/main/java/org/traccar/api/security/PermissionsService.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/org/traccar/api/security/PermissionsService.java b/src/main/java/org/traccar/api/security/PermissionsService.java
index a494c0257..ddfaaab94 100644
--- a/src/main/java/org/traccar/api/security/PermissionsService.java
+++ b/src/main/java/org/traccar/api/security/PermissionsService.java
@@ -170,8 +170,10 @@ public class PermissionsService {
|| before.getFixedEmail() != after.getFixedEmail()) {
if (userId == after.getId()) {
checkAdmin(userId);
- } else {
+ } else if (after.getId() > 0) {
checkUser(userId, after.getId());
+ } else {
+ checkManager(userId);
}
}
if (before.getFixedEmail() && !before.getEmail().equals(after.getEmail())) {