File tree 2 files changed +3
-4
lines changed
kotlin/src/main/kotlin/io/appwrite/services
2 files changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -149,9 +149,8 @@ namespace {{ spec.title | caseUcfirst }}
149
149
new HttpMethod(method),
150
150
_endpoint + path + queryString);
151
151
152
- if ("multipart/form-data".Equals(
153
- headers["content-type"],
154
- StringComparison.OrdinalIgnoreCase))
152
+ if (headers.TryGetValue("content-type", out var contentType) &&
153
+ "multipart/form-data".Equals(contentType, StringComparison.OrdinalIgnoreCase))
155
154
{
156
155
var form = new MultipartFormDataContent();
157
156
Original file line number Diff line number Diff line change @@ -55,7 +55,7 @@ class {{ service.name | caseUcfirst }}(client: Client) : Service(client) {
55
55
"{{ parameter .name }}" to {{ parameter .name | caseCamel }},
56
56
{%~ endfor %}
57
57
)
58
- val apiHeaders = mutableMapOf(
58
+ val apiHeaders = mutableMapOf< String , String > (
59
59
{%~ for key , header in method .headers %}
60
60
"{{ key }}" to "{{ header }}",
61
61
{%~ endfor %}
You can’t perform that action at this time.
0 commit comments