defaultDioExceptionReadableStringBuilder function
The default implementation of building a readable string of DioException.
Implementation
String defaultDioExceptionReadableStringBuilder(DioException e) {
final buffer = StringBuffer(
'DioException [${e.type.toPrettyDescription()}]: '
'${e.message}',
);
if (e.error != null) {
buffer.writeln();
buffer.write('Error: ${e.error}');
}
return buffer.toString();
}