parent
f02c3ec39a
commit
3b2d403292
|
@ -19,6 +19,7 @@
|
|||
|
||||
package org.elasticsearch.common.settings.loader;
|
||||
|
||||
import org.elasticsearch.ElasticSearchParseException;
|
||||
import org.elasticsearch.common.xcontent.XContentFactory;
|
||||
import org.elasticsearch.common.xcontent.XContentParser;
|
||||
import org.elasticsearch.common.xcontent.XContentType;
|
||||
|
@ -66,6 +67,9 @@ public abstract class XContentSettingsLoader implements SettingsLoader {
|
|||
if (token == null) {
|
||||
return settings;
|
||||
}
|
||||
if (token != XContentParser.Token.START_OBJECT) {
|
||||
throw new ElasticSearchParseException("malformed, expected settings to start with 'object', instead was [" + token + "]");
|
||||
}
|
||||
serializeObject(settings, sb, path, jp, null);
|
||||
return settings;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue