aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/traccar/api/resource
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2022-06-25 14:24:08 -0700
committerAnton Tananaev <anton@traccar.org>2022-06-25 14:24:08 -0700
commitbf0173eb4bac4ab86b43f101eb013051bfc40817 (patch)
tree166beb98c54799a62922762f70be9a9556bb01f0 /src/main/java/org/traccar/api/resource
parent2fcffc5b55f59310d289a21d1ebc2ee6bf15bcd5 (diff)
downloadtrackermap-server-bf0173eb4bac4ab86b43f101eb013051bfc40817.tar.gz
trackermap-server-bf0173eb4bac4ab86b43f101eb013051bfc40817.tar.bz2
trackermap-server-bf0173eb4bac4ab86b43f101eb013051bfc40817.zip
Simplify broadcast calls
Diffstat (limited to 'src/main/java/org/traccar/api/resource')
-rw-r--r--src/main/java/org/traccar/api/resource/DeviceResource.java1
-rw-r--r--src/main/java/org/traccar/api/resource/PermissionsResource.java10
2 files changed, 0 insertions, 11 deletions
diff --git a/src/main/java/org/traccar/api/resource/DeviceResource.java b/src/main/java/org/traccar/api/resource/DeviceResource.java
index e205f2d28..8791a82f9 100644
--- a/src/main/java/org/traccar/api/resource/DeviceResource.java
+++ b/src/main/java/org/traccar/api/resource/DeviceResource.java
@@ -138,7 +138,6 @@ public class DeviceResource extends BaseObjectResource<Device> {
cacheManager.addDevice(position.getDeviceId());
cacheManager.updatePosition(position);
connectionManager.updatePosition(true, position);
- broadcastService.updatePosition(true, position);
} finally {
cacheManager.removeDevice(position.getDeviceId());
}
diff --git a/src/main/java/org/traccar/api/resource/PermissionsResource.java b/src/main/java/org/traccar/api/resource/PermissionsResource.java
index 5ca865c31..44fc897ac 100644
--- a/src/main/java/org/traccar/api/resource/PermissionsResource.java
+++ b/src/main/java/org/traccar/api/resource/PermissionsResource.java
@@ -17,7 +17,6 @@
package org.traccar.api.resource;
import org.traccar.api.BaseResource;
-import org.traccar.broadcast.BroadcastService;
import org.traccar.helper.LogAction;
import org.traccar.model.Permission;
import org.traccar.model.UserRestrictions;
@@ -46,9 +45,6 @@ public class PermissionsResource extends BaseResource {
@Inject
private CacheManager cacheManager;
- @Inject
- private BroadcastService broadcastService;
-
private void checkPermission(Permission permission) throws StorageException {
if (permissionsService.notAdmin(getUserId())) {
permissionsService.checkPermission(permission.getOwnerClass(), getUserId(), permission.getOwnerId());
@@ -78,9 +74,6 @@ public class PermissionsResource extends BaseResource {
cacheManager.invalidatePermission(
permission.getOwnerClass(), permission.getOwnerId(),
permission.getPropertyClass(), permission.getPropertyId());
- broadcastService.invalidatePermission(
- permission.getOwnerClass(), permission.getOwnerId(),
- permission.getPropertyClass(), permission.getPropertyId());
LogAction.link(getUserId(),
permission.getOwnerClass(), permission.getOwnerId(),
permission.getPropertyClass(), permission.getPropertyId());
@@ -105,9 +98,6 @@ public class PermissionsResource extends BaseResource {
cacheManager.invalidatePermission(
permission.getOwnerClass(), permission.getOwnerId(),
permission.getPropertyClass(), permission.getPropertyId());
- broadcastService.invalidatePermission(
- permission.getOwnerClass(), permission.getOwnerId(),
- permission.getPropertyClass(), permission.getPropertyId());
LogAction.unlink(getUserId(),
permission.getOwnerClass(), permission.getOwnerId(),
permission.getPropertyClass(), permission.getPropertyId());