aboutsummaryrefslogtreecommitdiff
path: root/src/com/juick/server/MessagesQueries.java
diff options
context:
space:
mode:
authorGravatar Ugnich Anton2014-07-15 16:56:38 +0700
committerGravatar Ugnich Anton2014-07-15 16:56:38 +0700
commitb67b2f126af0c410cdb5b1a925d19b5d2cc5b2b2 (patch)
tree203acd2825fad6a482f923ad78b20448427510fb /src/com/juick/server/MessagesQueries.java
parentbddf6ce9dd9b9a1ed4b57df78ca1dcb3ed5a4bdd (diff)
User.Banned
Diffstat (limited to 'src/com/juick/server/MessagesQueries.java')
-rw-r--r--src/com/juick/server/MessagesQueries.java11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/com/juick/server/MessagesQueries.java b/src/com/juick/server/MessagesQueries.java
index 124f3898..fbdd7e69 100644
--- a/src/com/juick/server/MessagesQueries.java
+++ b/src/com/juick/server/MessagesQueries.java
@@ -951,7 +951,7 @@ public class MessagesQueries {
PreparedStatement stmt = null;
ResultSet rs = null;
try {
- stmt = sql.prepareStatement("SELECT replies.reply_id,replies.replyto,replies.user_id,users.nick,replies.txt,TIMESTAMPDIFF(MINUTE,replies.ts,NOW()),DATE_FORMAT(replies.ts,'%Y-%m-%d %H:%i:%s'),replies.attach FROM replies INNER JOIN users ON replies.user_id=users.id WHERE replies.message_id=? ORDER BY replies.reply_id ASC");
+ stmt = sql.prepareStatement("SELECT replies.reply_id,replies.replyto,replies.user_id,users.nick,users.banned,replies.txt,TIMESTAMPDIFF(MINUTE,replies.ts,NOW()),DATE_FORMAT(replies.ts,'%Y-%m-%d %H:%i:%s'),replies.attach FROM replies INNER JOIN users ON replies.user_id=users.id WHERE replies.message_id=? ORDER BY replies.reply_id ASC");
stmt.setInt(1, mid);
rs = stmt.executeQuery();
rs.beforeFirst();
@@ -963,10 +963,11 @@ public class MessagesQueries {
msg.User = new com.juick.User();
msg.User.UID = rs.getInt(3);
msg.User.UName = rs.getString(4);
- msg.Text = rs.getString(5);
- msg.TimeAgo = rs.getInt(6);
- msg.TimestampString = rs.getString(7);
- msg.AttachmentType = rs.getString(8);
+ msg.User.Banned = rs.getBoolean(5);
+ msg.Text = rs.getString(6);
+ msg.TimeAgo = rs.getInt(7);
+ msg.TimestampString = rs.getString(8);
+ msg.AttachmentType = rs.getString(9);
replies.add(msg);
}