properly take offset and length into account (introduced with realtime get)

This commit is contained in:
kimchy 2011-06-27 21:51:14 +03:00
parent f851279db1
commit 475564449f
1 changed files with 1 additions and 1 deletions

View File

@ -91,7 +91,7 @@ public class RestXContentBuilder {
} else { } else {
XContentType contentType = XContentFactory.xContentType(source, offset, length); XContentType contentType = XContentFactory.xContentType(source, offset, length);
if (contentType == builder.contentType()) { if (contentType == builder.contentType()) {
builder.rawField("_source", source); builder.rawField("_source", source, offset, length);
} else { } else {
XContentParser parser = XContentFactory.xContent(contentType).createParser(source); XContentParser parser = XContentFactory.xContent(contentType).createParser(source);
try { try {