Skip to content

Commit

Permalink
Attempt to fix delete token
Browse files Browse the repository at this point in the history
  • Loading branch information
alainbodiguel committed Aug 22, 2024
1 parent ac2281c commit dffe468
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@ public void createOrUpdate(UUID userId, RefreshToken token) {

@Override
public void delete(RefreshToken token) {
currentSession().remove(token);
currentSession().flush();
if (read(token.getValue()).isPresent()) {
currentSession().remove(token);
currentSession().flush();
}
}
}

0 comments on commit dffe468

Please sign in to comment.