app/authenticators/oauth2.js
/**
     * Invoked when "navigator.online" event is trigerred.
     * This is a helper function to handle intermittent internet connectivity. Token is refreshed
     * when browser status becomes "online".
     */
Invoked when "navigator.online" event is trigerred.
This is a helper function to handle intermittent internet connectivity. Token is refreshed
when browser status becomes "online".
Invoked when " navigator . online " event is trigerred . This is a helper function to handle intermittent internet connectivity . Token is refreshed when browser status becomes " online " .
onOnline() {
        if (this.get('session.isAuthenticated')) {
            let autoRefresh = this.get('refreshAccessTokens');
            if (autoRefresh) {
                let expiresIn = this.get('session.data.authenticated.expires_in');
                let token = this.get('session.data.authenticated.refresh_token');
                return this._refreshAccessToken(expiresIn, token);
            }
        }
    }
onOnline ( ) { if ( this . get ( 'session.isAuthenticated' ) ) { let autoRefresh = this . get ( 'refreshAccessTokens' ) ; if ( autoRefresh ) { let expiresIn = this . get ( 'session.data.authenticated.expires_in' ) ; let token = this . get ( 'session.data.authenticated.refresh_token' ) ; return this . _refreshAccessToken ( expiresIn , token ) ; } } }
Invoked when "navigator.online" event is trigerred.
Invoked when " navigator . online " event is trigerred .