jsonObject method
Decodes body as a JSON object.
Implementation
Map<String, dynamic> jsonObject() {
if (body.trim().isEmpty) return <String, dynamic>{};
final value = jsonDecode(body);
if (value is! Map) {
throw const FormatException('Auth test request was not a JSON object');
}
return Map<String, dynamic>.from(value);
}