@ InterfaceAudience . Private protected void checkSession ( ) { if ( getAuthenticator ( ) != null ) { Authorizer auth = ( Authorizer ) getAuthenticator ( ) ; auth . setRemoteURL ( remote ) ; auth . setLocalUUID ( db . publicUUID ( ) ) ; } if ( getAuthenticator ( ) != null && getAuthenticator ( ) instanceof SessionCookieAuthorizer ) { // Sync Gateway session API is at /db/_session; try that first checkSessionAtPath ( "_session" ) ; } else { login ( ) ; } }
Before doing anything else determine whether we have an active login session .