aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/traccar/api/resource/NotificationResource.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/org/traccar/api/resource/NotificationResource.java')
-rw-r--r--src/main/java/org/traccar/api/resource/NotificationResource.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/org/traccar/api/resource/NotificationResource.java b/src/main/java/org/traccar/api/resource/NotificationResource.java
index a41d00cf3..8bc81a3a4 100644
--- a/src/main/java/org/traccar/api/resource/NotificationResource.java
+++ b/src/main/java/org/traccar/api/resource/NotificationResource.java
@@ -85,7 +85,7 @@ public class NotificationResource extends ExtendedObjectResource<Notification> {
public Collection<Typed> getNotificators(@QueryParam("announcement") boolean announcement) {
Set<String> announcementsUnsupported = Set.of("command", "web");
return notificatorManager.getAllNotificatorTypes().stream()
- .filter(typed -> !announcement || !announcementsUnsupported.contains(typed.getType()))
+ .filter(typed -> !announcement || !announcementsUnsupported.contains(typed.type()))
.collect(Collectors.toUnmodifiableSet());
}
@@ -94,7 +94,7 @@ public class NotificationResource extends ExtendedObjectResource<Notification> {
public Response testMessage() throws MessageException, StorageException {
User user = permissionsService.getUser(getUserId());
for (Typed method : notificatorManager.getAllNotificatorTypes()) {
- notificatorManager.getNotificator(method.getType()).send(null, user, new Event("test", 0), null);
+ notificatorManager.getNotificator(method.type()).send(null, user, new Event("test", 0), null);
}
return Response.noContent().build();
}