summaryrefslogtreecommitdiff
path: root/src/database/QueryUtils.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/database/QueryUtils.java')
-rw-r--r--src/database/QueryUtils.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/database/QueryUtils.java b/src/database/QueryUtils.java
index a37b806..dac3ffc 100644
--- a/src/database/QueryUtils.java
+++ b/src/database/QueryUtils.java
@@ -113,7 +113,11 @@ public class QueryUtils {
} else {
tweetStatement.setLong("retweetid", null);
}
- tweetStatement.setLong("replyid", tweet.in_reply_to_user_id);
+ if (tweet.in_reply_to_user_id != null) {
+ tweetStatement.setLong("replyid", tweet.in_reply_to_user_id);
+ } else {
+ tweetStatement.setLong("replyid", null);
+ }
// TODO: place is not a string...
if (tweet.place != null) {
tweetStatement.setString("place", tweet.place.full_name + " " + tweet.place.country);