Skip to content

Commit 9b5275f

Browse files
Red-Asukaysfscream
authored andcommitted
fix(typescript): skip library check
1 parent 983d172 commit 9b5275f

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

src/main/saveExcel.ts

+7-5
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,13 @@ const saveExcel = (win: BrowserWindow, filename: string, workbook: WorkBook) =>
1414
try {
1515
xlsx.writeFile(workbook, filePath)
1616
} catch (err) {
17-
dialog.showMessageBox({
18-
type: 'error',
19-
title: 'System',
20-
message: `An error ocurred creating the file ${err.toString()}`,
21-
})
17+
if (err instanceof Error) {
18+
dialog.showMessageBox({
19+
type: 'error',
20+
title: 'System',
21+
message: `An error ocurred creating the file ${err.toString()}`,
22+
})
23+
}
2224
caughtError = true
2325
}
2426
if (!caughtError) {

tsconfig.json

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
"sourceMap": true,
1515
"emitDecoratorMetadata": true,
1616
"baseUrl": ".",
17+
"skipLibCheck": true,
1718
"types": [
1819
"webpack-env",
1920
"mocha",

0 commit comments

Comments
 (0)