mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-17 18:35:25 +00:00
double check that there are mappings before trying to call the post process method
This commit is contained in:
parent
32127c4d73
commit
79ebcc31c5
@ -521,9 +521,11 @@ public class XContentDocumentMapper implements DocumentMapper, ToXContent {
|
||||
@Override public void processDocumentAfterIndex(Document doc) {
|
||||
for (Fieldable field : doc.getFields()) {
|
||||
FieldMappers fieldMappers = mappers().indexName(field.name());
|
||||
FieldMapper mapper = fieldMappers.mapper();
|
||||
if (mapper != null) {
|
||||
mapper.processFieldAfterIndex(field);
|
||||
if (fieldMappers != null) {
|
||||
FieldMapper mapper = fieldMappers.mapper();
|
||||
if (mapper != null) {
|
||||
mapper.processFieldAfterIndex(field);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user