Skip to content

Commit

Permalink
return null for add chain
Browse files Browse the repository at this point in the history
  • Loading branch information
chaitanyapotti committed Jan 7, 2024
1 parent dc3cb1d commit 3a77ddf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/controllers/PreferencesController.js
Original file line number Diff line number Diff line change
Expand Up @@ -839,7 +839,7 @@ class PreferencesController extends SafeEventEmitter {
const req = this.getAddChainRequest(id)
switch (data.status) {
case 'approved':
return resolve()
return resolve('null') // https://docs.metamask.io/wallet/reference/wallet_addethereumchain/
case 'rejected':
return reject(ethErrors.provider.userRejectedRequest(`Torus add chain: ${req.errorMsg || 'User denied add chain request.'}`))
default:
Expand Down

0 comments on commit 3a77ddf

Please sign in to comment.