removePrefix method

String removePrefix(
  1. String value,
  2. String prefix
)

Implementation

String removePrefix(String value, String prefix) {
  if(!value.startsWith(prefix)) {
    throw AFException("Expected $value to start with $prefix");
  }
  final result = value.substring(prefix.length);
  return result;
}