diff options
| author | timb <timb@mb.home> | 2010-03-17 13:10:11 -0700 |
|---|---|---|
| committer | timb <timb@mb.home> | 2010-03-17 13:10:11 -0700 |
| commit | e30b950396b7fb7f0b7e97dd083370fa4263300a (patch) | |
| tree | 5dc13e141c62a37ee6c6e3c101652f9357fefa6a /src/site.clj | |
| parent | 40949737dbed36d1bcd0429b214ff6893a20cfa5 (diff) | |
share to fb,tumblr etc
Diffstat (limited to 'src/site.clj')
| -rwxr-xr-x | src/site.clj | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/site.clj b/src/site.clj index e0a03e4..43e17a8 100755 --- a/src/site.clj +++ b/src/site.clj @@ -211,7 +211,7 @@ (defn fetch-messages-by-nick ([nick image-only] (fetch-messages-by-nick nick image-only 0)) ([nick image-only offset] - (let [query (str "SELECT m.content, m.created_on, u.nick, u.avatar + (let [query (str "SELECT m.content, m.created_on, m.message_id, u.nick, u.avatar FROM messages m, users u, rooms r WHERE m.user_id = u.user_id AND u.nick = ? AND r.room_id = m.room_id AND r.admin_only = false " @@ -412,7 +412,7 @@ (min (count directory) (* (inc offset) *per-directory-page*))) user-ids (apply str (interpose ", " (map #(%1 :user_id) users))) - qry (str "SELECT u.user_id, u.nick, u.avatar, m.content + qry (str "SELECT u.user_id, u.nick, u.avatar, m.content, m.message_id FROM users u, messages m WHERE u.user_id in (" user-ids ") AND m.user_id = u.user_id |
