app/scripts/keyring-controller.js
// and this is used to retrieve them from the keyringTypes array.
and this is used to retrieve them from the keyringTypes array.
and this is used to retrieve them from the keyringTypes array .
addNewKeyring (type, opts) {
    const Keyring = this.getKeyringClassForType(type)
    const keyring = new Keyring(opts)
    return keyring.deserialize(opts)
    .then(() => {
      return keyring.getAccounts()
    })
    .then((accounts) => {
      return this.checkForDuplicate(type, accounts)
    })
    .then((checkedAccounts) => {
      this.keyrings.push(keyring)
      return this.setupAccounts(checkedAccounts)
    })
    .then(() => this.persistAllKeyrings())
    .then(() => this.fullUpdate())
    .then(() => {
      this._updateMemStoreKeyrings()
      return keyring
    })
  }
addNewKeyring ( type , opts ) { const Keyring = this . getKeyringClassForType ( type ) const keyring = new Keyring ( opts ) return keyring . deserialize ( opts ) . then ( ( ) => { return keyring . getAccounts ( ) } ) . then ( ( accounts ) => { return this . checkForDuplicate ( type , accounts ) } ) . then ( ( checkedAccounts ) => { this . keyrings . push ( keyring ) return this . setupAccounts ( checkedAccounts ) } ) . then ( ( ) => this . persistAllKeyrings ( ) ) . then ( ( ) => this . fullUpdate ( ) ) . then ( ( ) => { this . _updateMemStoreKeyrings ( ) return keyring } ) }
and this is used to retrieve them from the keyringTypes array.
and this is used to retrieve them from the keyringTypes array .