Commit 4f8403a 1 parent 9a1437a commit 4f8403a Copy full SHA for 4f8403a
File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -71,14 +71,14 @@ export default class LocalStorageObjectProvider {
71
71
* @private
72
72
*/
73
73
persistSpace ( space ) {
74
- this . localStorage [ this . spaceKey ] = JSON . stringify ( space ) ;
74
+ this . localStorage . setItem ( this . spaceKey , JSON . stringify ( space ) ) ;
75
75
}
76
76
77
77
/**
78
78
* @private
79
79
*/
80
80
getSpace ( ) {
81
- return this . localStorage [ this . spaceKey ] ;
81
+ return this . localStorage . getItem ( this . spaceKey ) ;
82
82
}
83
83
84
84
/**
@@ -93,14 +93,14 @@ export default class LocalStorageObjectProvider {
93
93
*/
94
94
initializeSpace ( ) {
95
95
if ( this . isEmpty ( ) ) {
96
- this . localStorage [ this . spaceKey ] = JSON . stringify ( { } ) ;
96
+ this . localStorage . setItem ( this . spaceKey , JSON . stringify ( { } ) ) ;
97
97
}
98
98
}
99
99
100
100
/**
101
101
* @private
102
102
*/
103
103
isEmpty ( ) {
104
- return this . getSpace ( ) === undefined ;
104
+ return this . getSpace ( ) === null ;
105
105
}
106
106
}
You can’t perform that action at this time.
0 commit comments