copyWith<T> method
Implementation
APIResponse<T> copyWith<T>({
bool? success,
String? message,
int? statusCode,
Map<String, String>? errors,
T? value,
dynamic body,
Map<String, String>? headers,
}) => APIResponse<T>(
success: success ?? this.success,
message: message ?? this.message,
statusCode: statusCode ?? this.statusCode,
errors: errors ?? this.errors,
value: value ?? this.value as T?,
body: body ?? this.body,
headers: headers ?? this.headers,
);