Skip to content

Commit a02e114

Browse files
committed
refactor: remove string/array type confusion by using only array
1 parent 04a38c7 commit a02e114

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/WebViewShared.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ const isDownloadMessageAllowed = ({
8787
return false;
8888
}
8989

90-
return Boolean(downloadWhitelist.find((rule) => rule.origin === origin && rule.allowedFileExtensions.includes(fileExtension)));
90+
return Boolean(downloadWhitelist.find((rule) => rule.origin === origin && [rule.allowedFileExtensions].flat().includes(fileExtension)));
9191
};
9292

9393
const urlToProtocolScheme = (url: string): string | null => {

0 commit comments

Comments
 (0)