mirror of
https://github.com/Athou/commafeed.git
synced 2026-10-27 15:38:47 +00:00
remove the possibility to receive notifications when subscribing because that sends a lot of notifications, one for each entry in the feed
This commit is contained in:
@@ -27,8 +27,4 @@ public class SubscribeRequest implements Serializable {
|
||||
@Schema(description = "id of the user category to place the feed in")
|
||||
@Size(max = 128)
|
||||
private String categoryId;
|
||||
|
||||
@Schema(description = "whether to send push notifications for new entries of this feed")
|
||||
private boolean pushNotificationsEnabled;
|
||||
|
||||
}
|
||||
|
||||
@@ -365,8 +365,7 @@ public class FeedREST {
|
||||
|
||||
FeedInfo info = fetchFeedInternal(prependHttp(req.getUrl()));
|
||||
User user = authenticationContext.getCurrentUser();
|
||||
long subscriptionId = feedSubscriptionService.subscribe(user, info.getUrl(), req.getTitle(), category, 0,
|
||||
req.isPushNotificationsEnabled());
|
||||
long subscriptionId = feedSubscriptionService.subscribe(user, info.getUrl(), req.getTitle(), category, 0);
|
||||
return Response.ok(subscriptionId).build();
|
||||
} catch (Exception e) {
|
||||
log.error("Failed to subscribe to URL {}: {}", req.getUrl(), e.getMessage(), e);
|
||||
@@ -385,7 +384,7 @@ public class FeedREST {
|
||||
Preconditions.checkNotNull(url);
|
||||
FeedInfo info = fetchFeedInternal(prependHttp(url));
|
||||
User user = authenticationContext.getCurrentUser();
|
||||
feedSubscriptionService.subscribe(user, info.getUrl(), info.getTitle(), null, 0, false);
|
||||
feedSubscriptionService.subscribe(user, info.getUrl(), info.getTitle(), null, 0);
|
||||
} catch (Exception e) {
|
||||
log.info("Could not subscribe to url {} : {}", url, e.getMessage());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user