Separate developmentMode conditional to only wrap log.

feature/default_network_editable
Kevin Serrano 8 years ago
parent b3def32f7a
commit 243d83dd33
  1. 6
      app/scripts/metamask-controller.js

@ -94,8 +94,10 @@ module.exports = class MetamaskController {
function logger (err, request, response) {
if (err) return console.error(err)
if (developmentMode && !request.isMetamaskInternal) {
console.log(`RPC (${originDomain}):`, request, '->', response)
if (!request.isMetamaskInternal) {
if (developmentMode) {
console.log(`RPC (${originDomain}):`, request, '->', response)
}
if (response.error) {
console.error('Error in RPC response:\n', response.error)
}

Loading…
Cancel
Save