Skip to content

Commit 451867d

Browse files
committed
Fix(enhanced-http): static analysis warning
1 parent 33d3a94 commit 451867d

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

packages/enhanced_http/lib/utils.dart

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,10 @@
11
class Utils {
2-
Map<String, String> mergeHeaders(
3-
Map<String, String>? h1, Map<String, String>? h2,
4-
[Map<String, String>? h3]) =>
5-
{...?h1, ...?h2, ...?h3};
2+
Map<String, String> mergeHeaders(Map<String, String>? h1, Map<String, String>? h2, [Map<String, String>? h3]) => {...?h1, ...?h2, ...?h3};
63

74
bool isStream(Map<String, String>? headers, [String? responseType = "json"]) {
8-
if ([headers?["Content-Type"], headers?["content-type"]]
9-
.contains("multipart/form-data") ||
10-
responseType == "stream") return true;
5+
if ([headers?["Content-Type"], headers?["content-type"]].contains("multipart/form-data") || responseType == "stream") {
6+
return true;
7+
}
118
return false;
129
}
1310
}

0 commit comments

Comments
 (0)