Skip to content

Commit dd6ffa6

Browse files
Yuval Talmoretalk
authored andcommitted
return undefined explicitly to avoid compilation errors
(cherry picked from commit 228e549)
1 parent 9514a98 commit dd6ffa6

File tree

2 files changed

+13
-13
lines changed

2 files changed

+13
-13
lines changed
Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
function getResponseHeader(response: AxiosResponse<any>, responseHeader?: string): string | undefined {
2-
if (responseHeader) {
3-
const content = response.headers[responseHeader];
4-
if (isString(content)) {
5-
return content;
6-
}
7-
}
8-
return;
9-
}
1+
const getResponseHeader = (response: AxiosResponse<any>, responseHeader?: string): string | undefined => {
2+
if (responseHeader) {
3+
const content = response.headers[responseHeader];
4+
if (isString(content)) {
5+
return content;
6+
}
7+
}
8+
return undefined;
9+
};

src/templates/core/functions/getFormData.hbs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ function getFormData(options: ApiRequestOptions): FormData | undefined {
2020
}
2121
});
2222

23-
return formData;
24-
}
25-
return;
26-
}
23+
return formData;
24+
}
25+
return undefined;
26+
};

0 commit comments

Comments
 (0)