From 3d485c0a81af602f17587b524b4ea394ed385d0e Mon Sep 17 00:00:00 2001 From: Bogdan Kostov Date: Wed, 10 Jul 2024 18:05:21 +0200 Subject: [PATCH] [Fix partially kbss-cvut/record-manager-ui#175] Disable SystemInitializer in oidc configuration --- src/main/java/cz/cvut/kbss/study/service/SystemInitializer.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/java/cz/cvut/kbss/study/service/SystemInitializer.java b/src/main/java/cz/cvut/kbss/study/service/SystemInitializer.java index 3d02624d..dc6795ff 100644 --- a/src/main/java/cz/cvut/kbss/study/service/SystemInitializer.java +++ b/src/main/java/cz/cvut/kbss/study/service/SystemInitializer.java @@ -6,8 +6,10 @@ import jakarta.annotation.PostConstruct; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; import org.springframework.stereotype.Service; +@ConditionalOnProperty(prefix = "security", name = "provider", havingValue = "internal", matchIfMissing = true) @Service public class SystemInitializer {