mirror of
https://gitlab.com/openstapps/openstapps.git
synced 2026-01-20 08:33:11 +00:00
build: upgrade to angular v12
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
* this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
import {NgModule} from '@angular/core';
|
||||
import {IonicStorageModule} from '@ionic/storage';
|
||||
import {IonicStorageModule} from '@ionic/storage-angular';
|
||||
import {StorageProvider} from './storage.provider';
|
||||
|
||||
/**
|
||||
|
||||
@@ -48,10 +48,10 @@ describe('StorageProvider', () => {
|
||||
});
|
||||
|
||||
it('should call ready method of storage on init', () => {
|
||||
spyOn(storage, 'ready');
|
||||
spyOn(storage, 'create');
|
||||
storageProvider.init();
|
||||
|
||||
expect(storage.ready).toHaveBeenCalled();
|
||||
expect(storage.create).toHaveBeenCalled();
|
||||
});
|
||||
|
||||
it('should call set method of storage to put a value', () => {
|
||||
|
||||
@@ -102,8 +102,8 @@ export class StorageProvider {
|
||||
/**
|
||||
* Initializes the storage (waits until it's ready)
|
||||
*/
|
||||
async init(): Promise<any> {
|
||||
return this.storage.ready();
|
||||
async init(): Promise<void> {
|
||||
await this.storage.create();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user