Skip to content

fix: Address TS issue #1036

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/default-storage/src/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ export function convertError(error?: ErrorLike): Error | null {
}

const out = new Error(error.message);
// @ts-expect-error Ignoring to keep backward compatibility
out["key"] = error.key;
return out;
}
Expand Down
2 changes: 1 addition & 1 deletion packages/default-storage/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export type MultiRequest = {
callback?: MultiGetCallback;
keyIndex: number;
resolve?: (result: readonly KeyValuePair[]) => void;
reject?: (error?: ErrorLike) => void;
reject?: (error?: Error) => void;
};

export type AsyncStorageHook = {
Expand Down
2 changes: 1 addition & 1 deletion packages/default-storage/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@
"expect-webdriverio"
]
},
"include": ["example/**/*.ts", "example/**/*.tsx"]
"include": ["example/**/*.ts", "example/**/*.tsx", "src"]
}