aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/api/resource/GeofenceResource.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/org/traccar/api/resource/GeofenceResource.java')
-rw-r--r--src/org/traccar/api/resource/GeofenceResource.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/org/traccar/api/resource/GeofenceResource.java b/src/org/traccar/api/resource/GeofenceResource.java
index df4947a1b..c9cc72bd7 100644
--- a/src/org/traccar/api/resource/GeofenceResource.java
+++ b/src/org/traccar/api/resource/GeofenceResource.java
@@ -94,7 +94,7 @@ public class GeofenceResource extends BaseResource {
@PUT
public Response update(Geofence entity) throws SQLException {
Context.getPermissionsManager().checkReadonly(getUserId());
- Context.getPermissionsManager().checkPermission("geofence", getUserId(), entity.getId());
+ Context.getPermissionsManager().checkPermission(Context.TYPE_GEOFENCE, getUserId(), entity.getId());
Context.getGeofenceManager().updateItem(entity);
return Response.ok(entity).build();
}
@@ -103,7 +103,7 @@ public class GeofenceResource extends BaseResource {
@DELETE
public Response remove(@PathParam("id") long id) throws SQLException {
Context.getPermissionsManager().checkReadonly(getUserId());
- Context.getPermissionsManager().checkPermission("geofence", getUserId(), id);
+ Context.getPermissionsManager().checkPermission(Context.TYPE_GEOFENCE, getUserId(), id);
Context.getGeofenceManager().removeItem(id);
return Response.noContent().build();
}