diff --git a/dio/lib/src/transformers/sync_transformer.dart b/dio/lib/src/transformers/sync_transformer.dart index 93366cbf0..db8af0ce9 100644 --- a/dio/lib/src/transformers/sync_transformer.dart +++ b/dio/lib/src/transformers/sync_transformer.dart @@ -31,7 +31,7 @@ class SyncTransformer extends Transformer { @override Future transformRequest(RequestOptions options) async { - final dynamic data = options.data ?? ''; + final Object data = options.data ?? ''; if (data is! String && Transformer.isJsonMimeType(options.contentType)) { return jsonEncodeCallback(data); } else if (data is Map) {