diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2017-02-27 22:17:56 +1300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-27 22:17:56 +1300 |
commit | 39452c3e0af164e6d63696afaf874c13c7ee8b5f (patch) | |
tree | d884f4065c7a9ef4291ad590a117ee7b22cc679c /src/org/traccar/database/PermissionsManager.java | |
parent | 61a1bae779f876bcdb9b83a8f950e678a170afb0 (diff) | |
parent | bb0a5ccd64ab8fa7c33ad9a6c37c695f2c3eef7e (diff) | |
download | trackermap-server-39452c3e0af164e6d63696afaf874c13c7ee8b5f.tar.gz trackermap-server-39452c3e0af164e6d63696afaf874c13c7ee8b5f.tar.bz2 trackermap-server-39452c3e0af164e6d63696afaf874c13c7ee8b5f.zip |
Merge pull request #2960 from Abyss777/server_devicereadonly
Server-wide "device readonly" flag
Diffstat (limited to 'src/org/traccar/database/PermissionsManager.java')
-rw-r--r-- | src/org/traccar/database/PermissionsManager.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/org/traccar/database/PermissionsManager.java b/src/org/traccar/database/PermissionsManager.java index 78589ad88..5313859df 100644 --- a/src/org/traccar/database/PermissionsManager.java +++ b/src/org/traccar/database/PermissionsManager.java @@ -223,7 +223,7 @@ public class PermissionsManager { } public void checkDeviceReadonly(long userId) throws SecurityException { - if (!isAdmin(userId) && isDeviceReadonly(userId)) { + if (!isAdmin(userId) && (server.getDeviceReadonly() || isDeviceReadonly(userId))) { throw new SecurityException("Account is device readonly"); } } |