summaryrefslogtreecommitdiff
path: root/src/site.clj
diff options
context:
space:
mode:
Diffstat (limited to 'src/site.clj')
-rw-r--r--src/site.clj10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/site.clj b/src/site.clj
index 45331c7..91f982e 100644
--- a/src/site.clj
+++ b/src/site.clj
@@ -17,7 +17,7 @@
admin
compojure
email
- fame
+ fame
utils
cookie-login
session-sweeper
@@ -145,7 +145,7 @@
(first (do-select [query (maybe-parse-int m-id -1)]))))
(defn fetch-public-message-by-id [m-id]
- (let [msg (fetch-message-by-id m-id)]
+ (let [msg (tags/fetch-dump-by-id m-id)]
(if (and msg (not (:admin_only msg)))
msg)))
@@ -570,8 +570,10 @@ FROM users u
; error if nick in url doesn't match the nick who posted the message from the id in url
; this prevents people from scraping all the content by incrementing the id in the url
(if (= (user-info :user_id) (message :user_id))
- (let [st (fetch-template "single_message" session)]
- (.setAttribute st "message" (process-message-for-output message))
+ (let [st (fetch-template "single_message" session)
+ message (tags/add-favorited-flag message session)
+ message (tags/remove-tags-for-output message)]
+ (.setAttribute st "dump" (process-message-for-output message))
(.toString st))
(resp-error "NO_MESSAGE"))
(resp-error "NO_MESSAGE"))