toResponse method
Converts the exception to a serializable response map (RFC 7807).
Implementation
@override
Map<String, dynamic> toResponse() {
final response = super.toResponse();
if (retryAfter != null) {
response['retry_after'] = retryAfter;
}
return response;
}