From 0c449fee4afd758af09b5e18e17f32785d541d1e Mon Sep 17 00:00:00 2001 From: Colin Goodheart-Smithe Date: Mon, 9 May 2016 10:55:15 +0100 Subject: [PATCH] small fix following rebase on master --- .../org/elasticsearch/index/mapper/DocumentParser.java | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/core/src/main/java/org/elasticsearch/index/mapper/DocumentParser.java b/core/src/main/java/org/elasticsearch/index/mapper/DocumentParser.java index 2e73223205a..dc67c4233d6 100644 --- a/core/src/main/java/org/elasticsearch/index/mapper/DocumentParser.java +++ b/core/src/main/java/org/elasticsearch/index/mapper/DocumentParser.java @@ -464,8 +464,7 @@ final class DocumentParser { context.path().remove(); } else { - // TODO: why Strings.splitStringToArray instead of String.split? - final String[] paths = Strings.splitStringToArray(currentFieldName, '.'); + final String[] paths = currentFieldName.split("\\."); currentFieldName = paths[paths.length - 1]; Tuple parentMapperTuple = getDynamicParentMapper(context, paths, mapper); ObjectMapper parentMapper = parentMapperTuple.v2(); @@ -509,8 +508,7 @@ final class DocumentParser { } } else { - // TODO: why Strings.splitStringToArray instead of String.split? - final String[] paths = Strings.splitStringToArray(arrayFieldName, '.'); + final String[] paths = arrayFieldName.split("\\."); arrayFieldName = paths[paths.length - 1]; lastFieldName = arrayFieldName; Tuple parentMapperTuple = getDynamicParentMapper(context, paths, parentMapper); @@ -574,8 +572,7 @@ final class DocumentParser { parseObjectOrField(context, mapper); } else { - // TODO: why Strings.splitStringToArray instead of String.split? - final String[] paths = Strings.splitStringToArray(currentFieldName, '.'); + final String[] paths = currentFieldName.split("\\."); currentFieldName = paths[paths.length - 1]; Tuple parentMapperTuple = getDynamicParentMapper(context, paths, parentMapper); parentMapper = parentMapperTuple.v2();