File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed
server/src/main/java/org/elasticsearch/index/mapper Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change 1010package org .elasticsearch .index .mapper ;
1111
1212import org .elasticsearch .core .CheckedFunction ;
13+ import org .elasticsearch .xcontent .ESBytesRef ;
1314import org .elasticsearch .xcontent .FilterXContentParser ;
1415import org .elasticsearch .xcontent .FilterXContentParserWrapper ;
1516import org .elasticsearch .xcontent .XContentLocation ;
@@ -379,6 +380,14 @@ public void skipChildren() throws IOException {
379380 }
380381 }
381382
383+ @ Override
384+ public ESBytesRef textRefOrNull () throws IOException {
385+ if (state == State .EXPANDING_START_OBJECT ) {
386+ throw new IllegalStateException ("Can't get text on a " + currentToken () + " at " + getTokenLocation ());
387+ }
388+ return super .textRefOrNull ();
389+ }
390+
382391 @ Override
383392 public String textOrNull () throws IOException {
384393 if (state == State .EXPANDING_START_OBJECT ) {
You can’t perform that action at this time.
0 commit comments