unexpectedResponse method
Implementation
@override
Never unexpectedResponse(http.BaseResponse response, Uint8List body) {
if (response.statusCode >= 400 && response.statusCode < 500) {
final resp = json.decode(utf8.decode(body));
if (resp is Map<String, Object?>) {
throw SDNException.fromJson(resp);
}
}
super.unexpectedResponse(response, body);
}