removeLastChar static method

String removeLastChar(
  1. String str
)

Implementation

static String  removeLastChar(String str ){
  //print( "_removeLastChar() - check: $str ");
  if (str != null && str.length > 0) {
    str = str.substring(0, str.length - 1);
  }
  //print( "_removeLastChar() - result: $str ");
  return str;
}