- String text = String.valueOf(data);
- int length = Numbers.safeParseInteger(parameters.get("length"), Numbers.safeParseInteger(templateContext.get(String.valueOf(parameters.get("length"))), -1));
- int cutOffLength = Numbers.safeParseInteger(parameters.get("cut-off-length"), Numbers.safeParseInteger(templateContext.get(String.valueOf(parameters.get("cut-off-length"))), length));
+ String text = valueOf(data);
+ int length = parseInt(valueOf(parameters.get("length")), -1);
+ int cutOffLength = parseInt(valueOf(parameters.get("cut-off-length")), length);