Skip to content

Commit

Permalink
fix(storage): Add wrapper function for storage clear (#42)
Browse files Browse the repository at this point in the history
  • Loading branch information
cihadturhan-st authored Sep 27, 2023
1 parent b275301 commit 73e4727
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/storage/src/defineExtensionStorage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,9 @@ export function defineExtensionStorage<TSchema extends AnySchema = AnySchema>(
}

return {
clear: storage.clear,
clear() {
return storage.clear();
},
getItem(key) {
return storage.get(key as string).then(res => res[key as string] ?? null);
},
Expand Down

0 comments on commit 73e4727

Please sign in to comment.