@rpcbase/client 0.54.0 → 0.55.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rpcbase/client",
3
- "version": "0.54.0",
3
+ "version": "0.55.0",
4
4
  "scripts": {
5
5
  "test": "echo \"Error: no test specified\" && exit 0"
6
6
  },
@@ -0,0 +1,18 @@
1
+ /* @flow */
2
+
3
+ const getEmptyStorage = () => {
4
+
5
+ const cacheStorage = {
6
+ get: async(key) => {
7
+ },
8
+ set: async(key, obj) => {
9
+ },
10
+ delete: async(key) => {
11
+ },
12
+ }
13
+
14
+ return cacheStorage
15
+ }
16
+
17
+
18
+ export default getEmptyStorage()
@@ -25,4 +25,4 @@ const getNativeStorage = () => {
25
25
  }
26
26
 
27
27
 
28
- export default getNativeStorage
28
+ export default getNativeStorage()
@@ -82,4 +82,4 @@ const getWebStorage = (
82
82
  }
83
83
 
84
84
 
85
- export default getWebStorage
85
+ export default getWebStorage()
@@ -6,7 +6,7 @@ import debug from "debug"
6
6
  import isEqual from "fast-deep-equal/react"
7
7
  import _omit from "lodash/omit"
8
8
 
9
- import get_uid from "@rpcbase/client/auth/get_uid"
9
+ import get_uid from "../auth/get_uid"
10
10
 
11
11
  import cacheStorage from "./cacheStorage"
12
12
 
@@ -1,12 +0,0 @@
1
- /* @flow */
2
- import {Platform} from "react-native"
3
-
4
- import getWebStorage from "./web"
5
- import getNativeStorage from "./native"
6
-
7
-
8
- // TODO: add support for storage expiration
9
-
10
- const storage = Platform.OS === "web" ? getWebStorage() : getNativeStorage()
11
-
12
- export default storage