aboutsummaryrefslogtreecommitdiff
path: root/src/com/juick
diff options
context:
space:
mode:
authorGravatar Ugnich Anton2014-02-14 13:21:26 +0700
committerGravatar Ugnich Anton2014-02-14 13:21:26 +0700
commit8af09519673b1549137c766eda6bdc72ba1b0b3d (patch)
tree552df73d37fe24219333c892ee393e35158b1325 /src/com/juick
parent18c9e608fa38b136e581adb974b29e4c5a446dc9 (diff)
MessagesQueries lang!=fa
Diffstat (limited to 'src/com/juick')
-rw-r--r--src/com/juick/server/MessagesQueries.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/com/juick/server/MessagesQueries.java b/src/com/juick/server/MessagesQueries.java
index dcba6830..dd284d3f 100644
--- a/src/com/juick/server/MessagesQueries.java
+++ b/src/com/juick/server/MessagesQueries.java
@@ -291,21 +291,21 @@ public class MessagesQueries {
try {
if (visitor_uid > 1) {
if (before > 0) {
- stmt = sql.prepareStatement("SELECT message_id FROM messages WHERE message_id<? AND (privacy>0 OR user_id=?) AND lang='ru' AND user_id NOT IN (SELECT bl_user_id FROM bl_users WHERE user_id=?) ORDER BY message_id DESC LIMIT 20");
+ stmt = sql.prepareStatement("SELECT message_id FROM messages WHERE message_id<? AND (privacy>0 OR user_id=?) AND lang!='fa' AND user_id NOT IN (SELECT bl_user_id FROM bl_users WHERE user_id=?) ORDER BY message_id DESC LIMIT 20");
stmt.setInt(1, before);
stmt.setInt(2, visitor_uid);
stmt.setInt(3, visitor_uid);
} else {
- stmt = sql.prepareStatement("SELECT message_id FROM messages WHERE (privacy>0 OR user_id=?) AND lang='ru' AND user_id NOT IN (SELECT bl_user_id FROM bl_users WHERE user_id=?) ORDER BY message_id DESC LIMIT 20");
+ stmt = sql.prepareStatement("SELECT message_id FROM messages WHERE (privacy>0 OR user_id=?) AND lang!='fa' AND user_id NOT IN (SELECT bl_user_id FROM bl_users WHERE user_id=?) ORDER BY message_id DESC LIMIT 20");
stmt.setInt(1, visitor_uid);
stmt.setInt(2, visitor_uid);
}
} else {
if (before > 0) {
- stmt = sql.prepareStatement("SELECT message_id FROM messages WHERE message_id<? AND privacy>0 AND lang='ru' ORDER BY message_id DESC LIMIT 20");
+ stmt = sql.prepareStatement("SELECT message_id FROM messages WHERE message_id<? AND privacy>0 AND lang!='fa' ORDER BY message_id DESC LIMIT 20");
stmt.setInt(1, before);
} else {
- stmt = sql.prepareStatement("SELECT message_id FROM messages WHERE privacy>0 AND lang='ru' ORDER BY message_id DESC LIMIT 20");
+ stmt = sql.prepareStatement("SELECT message_id FROM messages WHERE privacy>0 AND lang!='fa' ORDER BY message_id DESC LIMIT 20");
}
}