Skip to content

Commit

Permalink
only use host candidates as remote address
Browse files Browse the repository at this point in the history
  • Loading branch information
feross committed Jan 9, 2016
1 parent 99b3868 commit 08bc51d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ Peer.prototype._maybeReady = function () {

function onStats (items) {
items.forEach(function (item) {
if (item.type === 'remotecandidate') {
if (item.type === 'remotecandidate' && item.candidateType === 'host') {
self.remoteAddress = item.ipAddress
self.remotePort = Number(item.portNumber)
self.remoteFamily = 'IPv4'
Expand Down

0 comments on commit 08bc51d

Please sign in to comment.