mirror of
https://github.com/spring-projects/spring-security.git
synced 2025-06-25 21:42:17 +00:00
Fix for JdbcOneTimeTokenService cleanupExpiredTokens failing with PostgreSQL
Closes gh-16344
This commit is contained in:
parent
b9b29edbeb
commit
5075869418
@ -190,7 +190,8 @@ public final class JdbcOneTimeTokenService implements OneTimeTokenService, Dispo
|
||||
}
|
||||
|
||||
public void cleanupExpiredTokens() {
|
||||
List<SqlParameterValue> parameters = List.of(new SqlParameterValue(Types.TIMESTAMP, Instant.now()));
|
||||
List<SqlParameterValue> parameters = List
|
||||
.of(new SqlParameterValue(Types.TIMESTAMP, Timestamp.from(Instant.now())));
|
||||
PreparedStatementSetter pss = new ArgumentPreparedStatementSetter(parameters.toArray());
|
||||
int deletedCount = this.jdbcOperations.update(DELETE_ONE_TIME_TOKENS_BY_EXPIRY_TIME_QUERY, pss);
|
||||
if (this.logger.isDebugEnabled()) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user