diff --git a/htroot/Bookmarks.html b/htroot/Bookmarks.html index b76c3612f..41083d96e 100644 --- a/htroot/Bookmarks.html +++ b/htroot/Bookmarks.html @@ -38,6 +38,7 @@ +
#(edit)# diff --git a/htroot/Bookmarks.java b/htroot/Bookmarks.java index 7e5ceb266..011436b4f 100644 --- a/htroot/Bookmarks.java +++ b/htroot/Bookmarks.java @@ -77,7 +77,7 @@ public class Bookmarks { String tagName=""; int start=0; userDB.Entry user=switchboard.userDB.getUser(header); - boolean isAdmin=(switchboard.verifyAuthentication(header, true) || user!= null && user.hasBookmarkRight()); + boolean isAdmin=(switchboard.verifyAuthentication(header, true) || user!= null && user.hasRight(userDB.Entry.BOOKMARK_RIGHT)); String username=""; if(user != null) username=user.getUserName(); else if(isAdmin) username="admin"; @@ -102,6 +102,7 @@ public class Bookmarks { prop.put("mode_url", ""); prop.put("mode_tags", ""); prop.put("mode_public", 1); //1=is public + prop.put("mode_feed", 0); //no newsfeed if(post != null){ if(!isAdmin){ @@ -140,6 +141,11 @@ public class Bookmarks { }else{ bookmark.setPublic(false); } + if(((String) post.get("public")).equals("public")){ + bookmark.setFeed(true); + }else{ + bookmark.setFeed(false); + } bookmark.setTags(tags, true); switchboard.bookmarksDB.saveBookmark(bookmark); @@ -157,6 +163,7 @@ public class Bookmarks { prop.put("mode_url", (String) post.get("url")); prop.put("mode_tags", (String) post.get("tags")); prop.put("mode_public", 0); + prop.put("mode_feed", 0); } else { bookmarksDB.Bookmark bookmark = switchboard.bookmarksDB.getBookmark(urlHash); if (bookmark == null) { @@ -173,6 +180,7 @@ public class Bookmarks { prop.put("mode_author", comp.author()); prop.put("mode_tags", (document == null) ? comp.tags() : document.getKeywords(',')); prop.put("mode_public", 0); + prop.put("mode_feed", 0); //TODO: check if it IS a feed } if (document != null) document.close(); } else { @@ -256,7 +264,10 @@ public class Bookmarks { while(count