Removes the last character if it is Z
String removeEndingZ(String value) { return value.endsWith('Z') ? value.substring(0, value.length) : value; }