1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-22 09:57:02 +01:00

Merge pull request #611 from vincentserpoul/patch-1

Error message more helpful
This commit is contained in:
Kevin Serrano 2016-09-05 23:14:55 -07:00 committed by GitHub
commit f6be97d9cf

View File

@ -80,7 +80,8 @@ MetamaskInpageProvider.prototype.send = function (payload) {
// throw not-supported Error
default:
var message = 'The MetaMask Web3 object does not support synchronous methods. See https://github.com/MetaMask/faq/blob/master/DEVELOPERS.md#all-async---think-of-metamask-as-a-light-client for details.'
var message = 'The MetaMask Web3 object does not support synchronous methods like ' + payload.method +
'. See https://github.com/MetaMask/faq/blob/master/DEVELOPERS.md#all-async---think-of-metamask-as-a-light-client for details.'
throw new Error(message)
}
@ -131,4 +132,4 @@ function eachJsonMessage(payload, transformFn){
} else {
return transformFn(payload)
}
}
}