inpage - correctly listen for incomming messages

feature/default_network_editable
kumavis 8 years ago
parent 46bb9558d5
commit 26b60f1b5a
  1. 2
      app/scripts/inpage.js

@ -43,7 +43,7 @@ reloadStream.once('data', triggerReload)
var pingChannel = inpageProvider.multiStream.createStream('pingpong') var pingChannel = inpageProvider.multiStream.createStream('pingpong')
var pingStream = new PingStream({ objectMode: true }) var pingStream = new PingStream({ objectMode: true })
// wait for first successful reponse // wait for first successful reponse
metamaskStream.once('_data', function(){ metamaskStream.once('data', function(){
pingStream.pipe(pingChannel).pipe(pingStream) pingStream.pipe(pingChannel).pipe(pingStream)
}) })
endOfStream(pingStream, triggerReload) endOfStream(pingStream, triggerReload)

Loading…
Cancel
Save