Skip to content

Commit 249f77b

Browse files
author
Andrea Cosentino
committed
fix: mimeType handling
1 parent eaa6256 commit 249f77b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/utils/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ export const Utils = {
173173
const extFile = MimeTypeExt[mimeType];
174174
path += `${extFile ? extFile : typeof data === "string" ? ".txt" : ""}`;
175175
}
176-
if (mimeType != null && mimeType.toString() === MimeType[".json"] || !!ext && ext === MimeTypeExt["application/json"]) {
176+
if ((mimeType != null && mimeType.toString() === MimeType[".json"]) || (!!ext && ext === MimeTypeExt["application/json"])) {
177177
file = JSON.stringify(data, null, 2);
178178
options = { encoding: "utf-8" };
179179
} else {

0 commit comments

Comments
 (0)