createRequestOptions method
Implementation
Future<RequestOptions> createRequestOptions(TargetType targetType) async {
targetType.headers = targetType.headers ?? {};
targetType.headers?.addAll(await headers());
return RequestOptions(
method: targetType.method?.value,
headers: targetType.headers,
path: targetType.path!,
baseUrl: baseUrl,
receiveDataWhenStatusError: true,
validateStatus: (code) => true,
data: targetType.requestParameters,
);
}