Merge pull request #3355 from stianst/KEYCLOAK-2699
KEYCLOAK-2699 Potential for NPE in DirImportProvider.getRealmsToImport
This commit is contained in:
commit
13220e1d38
1 changed files with 4 additions and 0 deletions
|
@ -62,6 +62,10 @@ public class DirImportProvider implements ImportProvider {
|
||||||
public DirImportProvider(File rootDirectory) {
|
public DirImportProvider(File rootDirectory) {
|
||||||
this.rootDirectory = rootDirectory;
|
this.rootDirectory = rootDirectory;
|
||||||
|
|
||||||
|
if (!this.rootDirectory.exists()) {
|
||||||
|
throw new IllegalStateException("Directory " + this.rootDirectory + " doesn't exists");
|
||||||
|
}
|
||||||
|
|
||||||
logger.infof("Importing from directory %s", this.rootDirectory.getAbsolutePath());
|
logger.infof("Importing from directory %s", this.rootDirectory.getAbsolutePath());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue