Skip to content

Commit 484a088

Browse files
authored
Merge pull request #98 from 2skydev/dev
v0.0.19-re
2 parents a5a3c60 + acdd953 commit 484a088

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

.eslintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@ node_modules
22
dist
33
out
44
.gitignore
5+
generated-*

src/renderer/src/hooks/useAPI.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,9 @@ const useAPI = <FnName extends ElectronContextPropertyName>(
2323
revalidateOnFocus: false,
2424
revalidateOnReconnect: false,
2525
fetcher: async ([, args]: typeof key) => {
26-
// @ts-ignore
26+
// @ts-ignore: ...args
2727
const response = await window.electron[fnName](...args)
2828

29-
if (response?.errorCode) throw new Error(response?.message || 'Unknown Error')
30-
3129
return response
3230
},
3331
...swrOptions,

0 commit comments

Comments
 (0)