Return null for selected provider if empty string

This commit is contained in:
Stian Thorgersen 2014-06-24 17:44:30 +01:00
parent 34a1923d18
commit 711b8ca747
5 changed files with 10 additions and 5 deletions

View file

@ -16,7 +16,12 @@ public class Config {
}
public static String getProvider(String spi) {
return configProvider.getProvider(spi);
String provider = configProvider.getProvider(spi);
if (provider == null || provider.trim().equals("")) {
return null;
} else {
return provider;
}
}
public static Scope scope(String... scope) {

View file

@ -8,7 +8,7 @@
},
"modelCache": {
"provider": "${keycloak.model.cache.provider:simple}"
"provider": "${keycloak.model.cache.provider:}"
},
"timer": {

View file

@ -15,7 +15,7 @@
},
"modelCache": {
"provider": "${keycloak.model.cache.provider:simple}"
"provider": "${keycloak.model.cache.provider:}"
},
"timer": {

View file

@ -24,7 +24,7 @@
},
"modelCache": {
"provider": "${keycloak.model.cache.provider:none}"
"provider": "${keycloak.model.cache.provider:}"
},
"timer": {

View file

@ -15,7 +15,7 @@
},
"modelCache": {
"provider": "${keycloak.model.cache.provider:simple}"
"provider": "${keycloak.model.cache.provider:}"
},
"timer": {