Fixing bad quotation in string.substring

This commit is contained in:
markiantorno 2020-02-25 14:14:40 -05:00
parent 40d6cd4108
commit 5984a0c693
1 changed files with 1 additions and 1 deletions

View File

@ -3280,7 +3280,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
Gson gson = new Gson(); Gson gson = new Gson();
String json = gson.toJson((StringType) fixed); String json = gson.toJson((StringType) fixed);
String escapedString = json.substring(json.indexOf(":") + 2); String escapedString = json.substring(json.indexOf(":") + 2);
escapedString = escapedString.substring(0, escapedString.indexOf(",'myStringValue") - 1); escapedString = escapedString.substring(0, escapedString.indexOf(",\"myStringValue") - 1);
expression.append("'" + escapedString + "'"); expression.append("'" + escapedString + "'");
} else if (fixed instanceof UriType) { } else if (fixed instanceof UriType) {
expression.append("'" + ((UriType) fixed).asStringValue() + "'"); expression.append("'" + ((UriType) fixed).asStringValue() + "'");