diff options
| author | tim b <timb@camcompu.home> | 2010-06-24 23:13:08 -0700 |
|---|---|---|
| committer | tim b <timb@camcompu.home> | 2010-06-24 23:13:08 -0700 |
| commit | bb2e003f9f3362fca15272f527a6f87543ec1a21 (patch) | |
| tree | f52b0d778bdb7546224a947d43225c8e9e43aaf7 /src/site.clj | |
| parent | 15f5a8ed8e981486697790fe9613b1c26dceda42 (diff) | |
add fav to permalinks, link to conextual domain for local testing, longer fadeout on fav, cleanup some html
Diffstat (limited to 'src/site.clj')
| -rw-r--r-- | src/site.clj | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/site.clj b/src/site.clj index 0967431..fc2999f 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")) |
