diff --git a/main/src/com/google/refine/commands/column/SplitColumnCommand.java b/main/src/com/google/refine/commands/column/SplitColumnCommand.java index 4e95b22fe..0a9815e9a 100644 --- a/main/src/com/google/refine/commands/column/SplitColumnCommand.java +++ b/main/src/com/google/refine/commands/column/SplitColumnCommand.java @@ -35,8 +35,7 @@ package com.google.refine.commands.column; import javax.servlet.http.HttpServletRequest; -import org.json.JSONArray; - +import com.fasterxml.jackson.core.type.TypeReference; import com.google.refine.browsing.EngineConfig; import com.google.refine.commands.EngineDependentCommand; import com.google.refine.model.AbstractOperation; @@ -68,12 +67,7 @@ public class SplitColumnCommand extends EngineDependentCommand { } else { String s = request.getParameter("fieldLengths"); - JSONArray a = ParsingUtilities.evaluateJsonStringToArray(s); - int[] fieldLengths = new int[a.length()]; - - for (int i = 0; i < fieldLengths.length; i++) { - fieldLengths[i] = a.getInt(i); - } + int[] fieldLengths = ParsingUtilities.mapper.readValue(s, new TypeReference() {}); return new ColumnSplitOperation( engineConfig,