summaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorMatthias Andreas Benkard <code@mail.matthias.benkard.de>2020-04-19 18:43:15 +0200
committerMatthias Andreas Benkard <code@mail.matthias.benkard.de>2020-04-19 18:43:15 +0200
commitc5b99755e529bb3e5de04584115598e81a23eeb9 (patch)
tree4b4d9cdf0de46f54b914d8f8135f096e0d113638 /src/main
parentcf0fe88a5f1b0c53fb84b016128878db329141fc (diff)
KB49 Vary feed URI based on resource type rendered.
Change-Id: I02025bc5ce86aa6cda1b083c7a542cefb561c25d
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/eu/mulk/mulkcms2/benki/posts/PostResource.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/eu/mulk/mulkcms2/benki/posts/PostResource.java b/src/main/java/eu/mulk/mulkcms2/benki/posts/PostResource.java
index c100e55..2e67208 100644
--- a/src/main/java/eu/mulk/mulkcms2/benki/posts/PostResource.java
+++ b/src/main/java/eu/mulk/mulkcms2/benki/posts/PostResource.java
@@ -109,7 +109,7 @@ public abstract class PostResource {
var session = entityManager.unwrap(Session.class);
var q = Post.findViewable(postFilter, session, reader, null, cursor, maxResults);
- var feedUri = "/posts/feed";
+ var feedUri = uri.getPath() + "/feed";
if (reader != null) {
var pageKey = ensurePageKey(reader, feedUri);
feedUri += "?page-key=" + pageKey.key.toString(36);
@@ -143,7 +143,7 @@ public abstract class PostResource {
var session = entityManager.unwrap(Session.class);
var q = Post.findViewable(postFilter, session, reader, owner, cursor, maxResults);
- var feedUri = String.format("/posts/~%s/feed", ownerName);
+ var feedUri = uri.getPath() + "/feed";
if (reader != null) {
var pageKey = ensurePageKey(reader, feedUri);
feedUri += "?page-key=" + pageKey.key.toString(36);