diff options
Diffstat (limited to 'src/main/java/org/traccar/api')
-rw-r--r-- | src/main/java/org/traccar/api/resource/DeviceResource.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/main/java/org/traccar/api/resource/DeviceResource.java b/src/main/java/org/traccar/api/resource/DeviceResource.java index 8e634232a..89bba7237 100644 --- a/src/main/java/org/traccar/api/resource/DeviceResource.java +++ b/src/main/java/org/traccar/api/resource/DeviceResource.java @@ -210,6 +210,9 @@ public class DeviceResource extends BaseObjectResource<Device> { if (user.getTemporary()) { throw new SecurityException("Temporary user"); } + if (user.getExpirationTime() != null && user.getExpirationTime().before(expiration)) { + expiration = user.getExpirationTime(); + } Device device = storage.getObject(Device.class, new Request( new Columns.All(), |