aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2016-01-16 19:04:26 +0300
committerGravatar Vitaly Takmazov2016-01-16 19:04:26 +0300
commit279765857724cf35addc0e3f5e7180a8724d23b9 (patch)
tree12745540f8649defe57304b9ca59c2295f3c7804 /src/main
parent714a267ae35354e86512288e0ac91990937f95ab (diff)
fix time of messages
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/com/juick/server/MessagesQueries.java8
-rw-r--r--src/main/java/com/juick/server/PMQueries.java6
2 files changed, 7 insertions, 7 deletions
diff --git a/src/main/java/com/juick/server/MessagesQueries.java b/src/main/java/com/juick/server/MessagesQueries.java
index fd664909..1d8eceb3 100644
--- a/src/main/java/com/juick/server/MessagesQueries.java
+++ b/src/main/java/com/juick/server/MessagesQueries.java
@@ -225,7 +225,7 @@ public class MessagesQueries {
msg.getUser().setUID(rs.getInt(1));
msg.getUser().setUName(rs.getString(2));
msg.TimeAgo = rs.getInt(3);
- msg.setDate(rs.getDate(4));
+ msg.setDate(rs.getTimestamp(4));
msg.ReadOnly = rs.getBoolean(5);
msg.Privacy = rs.getInt(6);
msg.FriendsOnly = msg.Privacy < 0;
@@ -265,7 +265,7 @@ public class MessagesQueries {
msg.getUser().setUID(rs.getInt(1));
msg.getUser().setUName(rs.getString(2));
msg.ReplyTo = rs.getInt(3);
- msg.setDate(rs.getDate(4));
+ msg.setDate(rs.getTimestamp(4));
msg.AttachmentType = rs.getString(5);
msg.setText(rs.getString(6));
return msg;
@@ -885,7 +885,7 @@ public class MessagesQueries {
msg.FriendsOnly = msg.Privacy < 0;
msg.setText(rs.getString(7));
msg.TimeAgo = rs.getInt(8);
- msg.setDate(rs.getDate(9));
+ msg.setDate(rs.getTimestamp(9));
msg.Replies = rs.getInt(10);
msg.RepliesBy = rs.getString(11);
msg.AttachmentType = rs.getString(12);
@@ -920,7 +920,7 @@ public class MessagesQueries {
msg.getUser().Banned = rs.getBoolean(5);
msg.setText(rs.getString(6));
msg.TimeAgo = rs.getInt(7);
- msg.setDate(rs.getDate(8));
+ msg.setDate(rs.getTimestamp(8));
msg.AttachmentType = rs.getString(9);
replies.add(msg);
diff --git a/src/main/java/com/juick/server/PMQueries.java b/src/main/java/com/juick/server/PMQueries.java
index 345f641f..9ff464ba 100644
--- a/src/main/java/com/juick/server/PMQueries.java
+++ b/src/main/java/com/juick/server/PMQueries.java
@@ -154,7 +154,7 @@ public class PMQueries {
msg.setUser(new User());
msg.getUser().setUID(uuid);
msg.setText(rs.getString(2));
- msg.setDate(rs.getDate(3));
+ msg.setDate(rs.getTimestamp(3));
return msg;
}, new Object[]{uid, uid_to, uid, uid_to});
@@ -181,7 +181,7 @@ public class PMQueries {
msg.getUser().setUName(rs.getString(2));
msg.setText(rs.getString(3));
msg.TimeAgo = rs.getInt(4);
- msg.setDate(rs.getDate(5));
+ msg.setDate(rs.getTimestamp(5));
msgs.add(0, msg);
}
} catch (SQLException e) {
@@ -210,7 +210,7 @@ public class PMQueries {
msg.getUser().setUName(rs.getString(2));
msg.setText(rs.getString(3));
msg.TimeAgo = rs.getInt(4);
- msg.setDate(rs.getDate(5));
+ msg.setDate(rs.getTimestamp(5));
msgs.add(0, msg);
}
} catch (SQLException e) {