From 19c67f48e5436fae0c3ce84ab7340516d80bdcf4 Mon Sep 17 00:00:00 2001 From: Glandos Date: Fri, 24 Jul 2020 14:54:40 +0200 Subject: [PATCH] Update localforage.d.ts getItem can return null when the item doesn't exist --- typings/localforage.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/typings/localforage.d.ts b/typings/localforage.d.ts index 34e0db2a..7fb8f58a 100644 --- a/typings/localforage.d.ts +++ b/typings/localforage.d.ts @@ -15,7 +15,7 @@ interface LocalForageOptions extends LocalForageDbInstanceOptions { } interface LocalForageDbMethodsCore { - getItem(key: string, callback?: (err: any, value: T) => void): Promise; + getItem(key: string, callback?: (err: any, value: T | null) => void): Promise; setItem(key: string, value: T, callback?: (err: any, value: T) => void): Promise;