From 6d6a230f70e7a93a39b3b39a6c8149066c4aacf6 Mon Sep 17 00:00:00 2001 From: Colin Goodheart-Smithe Date: Mon, 24 Apr 2017 10:20:15 +0100 Subject: [PATCH] Makes StoredScriptSource implement ToXContentObject --- .../org/elasticsearch/script/StoredScriptSource.java | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/core/src/main/java/org/elasticsearch/script/StoredScriptSource.java b/core/src/main/java/org/elasticsearch/script/StoredScriptSource.java index 11215fded34..b4e6e257eb7 100644 --- a/core/src/main/java/org/elasticsearch/script/StoredScriptSource.java +++ b/core/src/main/java/org/elasticsearch/script/StoredScriptSource.java @@ -34,7 +34,7 @@ import org.elasticsearch.common.io.stream.Writeable; import org.elasticsearch.common.xcontent.NamedXContentRegistry; import org.elasticsearch.common.xcontent.ObjectParser; import org.elasticsearch.common.xcontent.ObjectParser.ValueType; -import org.elasticsearch.common.xcontent.ToXContent; +import org.elasticsearch.common.xcontent.ToXContentObject; import org.elasticsearch.common.xcontent.XContentBuilder; import org.elasticsearch.common.xcontent.XContentFactory; import org.elasticsearch.common.xcontent.XContentParser; @@ -52,7 +52,7 @@ import java.util.Objects; * {@link StoredScriptSource} represents user-defined parameters for a script * saved in the {@link ClusterState}. */ -public class StoredScriptSource extends AbstractDiffable implements Writeable, ToXContent { +public class StoredScriptSource extends AbstractDiffable implements Writeable, ToXContentObject { /** * Standard {@link ParseField} for outer level of stored script source. @@ -426,11 +426,6 @@ public class StoredScriptSource extends AbstractDiffable imp return builder; } - @Override - public boolean isFragment() { - return false; - } - /** * @return The language used for compiling this script. */