src/scope/Application.js
/**
   * Login user using EVRYTHNG credentials and create User scope on success.
   *
   * @param {AccessCredentials} credentials - User login credentials
   * @param {Function} callback - Error first callback
   * @returns {Promise.<User>} - Authorized User scope
   */
Login user using EVRYTHNG credentials and create User scope on success.
@param {AccessCredentials} credentials - User login credentials
@param {Function} callback - Error first callback
@returns {Promise.} - Authorized User scope
Login user using EVRYTHNG credentials and create User scope on success . @param { AccessCredentials } credentials - User login credentials @param { Function } callback - Error first callback @returns { Promise . } - Authorized User scope
async login (credentials, callback) {
    try {
      const user = await this._authenticateUser(credentials)
      const userScope = new User(user.access.apiKey, user)
      await userScope.init()
      if (callback) callback(null, userScope)
      return userScope
    } catch (err) {
      if (callback) callback(err)
      throw err
    }
  }
async login ( credentials , callback ) { try { const user = await this . _authenticateUser ( credentials ) const userScope = new User ( user . access . apiKey , user ) await userScope . init ( ) if ( callback ) callback ( null , userScope ) return userScope } catch ( err ) { if ( callback ) callback ( err ) throw err } }
Login user using EVRYTHNG credentials and create User scope on success.
Login user using EVRYTHNG credentials and create User scope on success .