E3A9 Avoid exceptions on cleanup if previous setup failed by ahus1 · Pull Request #54798 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
DB4F
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ public static void enableTestingTimeService(KeycloakSession session) {

public static void disableTestingTimeService(KeycloakSession session) {
if (origTimeService == null) {
throw new IllegalStateException("Calling revertTimeService when testing TimeService was not set");
// Nothing to revert, for example when resetting the offset after the request that enabled it failed
logger.warn("Not reverting the testing TimeService as it was not set");
return;
}

origTimeService.run();
Expand Down
Loading
0