src/store/indexeddb-local-backend.js
function() {
        return Promise.all([
            this._loadAccountData(),
            this._loadSyncData(),
        ]).then(([accountData, syncData]) => {
            console.log(
                `LocalIndexedDBStoreBackend: loaded initial data`,
            );
            this._syncAccumulator.accumulate({
                next_batch: syncData.nextBatch,
                rooms: syncData.roomsData,
                groups: syncData.groupsData,
                account_data: {
                    events: accountData,
                },
            });
        });
    }
function() {
        return Promise.all([
            this._loadAccountData(),
            this._loadSyncData(),
        ]).then(([accountData, syncData]) => {
            console.log(
                `LocalIndexedDBStoreBackend: loaded initial data`,
            );
            this._syncAccumulator.accumulate({
                next_batch: syncData.nextBatch,
                rooms: syncData.roomsData,
                groups: syncData.groupsData,
                account_data: {
                    events: accountData,
                },
            });
        });
    }
function ( ) { return Promise . all ( [ this . _loadAccountData ( ) , this . _loadSyncData ( ) , ] ) . then ( ( [ accountData , syncData ] ) => { console . log ( ` ` , ) ; this . _syncAccumulator . accumulate ( { next_batch : syncData . nextBatch , rooms : syncData . roomsData , groups : syncData . groupsData , account_data : { events : accountData , } , } ) ; } ) ; }
Having connected, load initial data from the database and prepare for use
@return {Promise} Resolves on success
Having connected load initial data from the database and prepare for use