diff options
author | Vitaly Takmazov | 2023-02-01 20:22:05 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2023-02-01 21:29:08 +0300 |
commit | 57222853c90b0ffc4b800adeeddc289d58ee0a25 (patch) | |
tree | 8d658ed98a48fbe7e078ce7da7a4c17c405ffb7a /src/main/java/com/juick/service/EmailServiceImpl.java | |
parent | 225b85bfd43753a4748dca2bc47b7018294cdfd3 (diff) |
Store timestamp in milliseconds when using SQLite
Diffstat (limited to 'src/main/java/com/juick/service/EmailServiceImpl.java')
-rw-r--r-- | src/main/java/com/juick/service/EmailServiceImpl.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/com/juick/service/EmailServiceImpl.java b/src/main/java/com/juick/service/EmailServiceImpl.java index 7f358533..85e56a05 100644 --- a/src/main/java/com/juick/service/EmailServiceImpl.java +++ b/src/main/java/com/juick/service/EmailServiceImpl.java @@ -119,6 +119,6 @@ public class EmailServiceImpl extends BaseJdbcService implements EmailService { Instant day = Instant.now().minus(1, ChronoUnit.DAYS); return getNamedParameterJdbcTemplate().update("DELETE FROM auth WHERE ts < :day", new MapSqlParameterSource() - .addValue("day", day.atOffset(ZoneOffset.UTC), Types.TIMESTAMP_WITH_TIMEZONE)); + .addValue("day", toDateTime(day.atOffset(ZoneOffset.UTC)), dateTimeType())); } } |