fix test for existance of directory based mappings when creating an index
This commit is contained in:
parent
0186a03684
commit
9af288a42f
|
@ -127,11 +127,11 @@ public class MetaDataCreateIndexService extends AbstractComponent {
|
|||
File mappingsDir = new File(environment.configFile(), "mappings");
|
||||
if (mappingsDir.exists() && mappingsDir.isDirectory()) {
|
||||
File defaultMappingsDir = new File(mappingsDir, "_default");
|
||||
if (mappingsDir.exists() && mappingsDir.isDirectory()) {
|
||||
if (defaultMappingsDir.exists() && defaultMappingsDir.isDirectory()) {
|
||||
addMappings(mappings, defaultMappingsDir);
|
||||
}
|
||||
File indexMappingsDir = new File(mappingsDir, request.index);
|
||||
if (mappingsDir.exists() && mappingsDir.isDirectory()) {
|
||||
if (indexMappingsDir.exists() && indexMappingsDir.isDirectory()) {
|
||||
addMappings(mappings, indexMappingsDir);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue