Skip to content

Commit

Permalink
Revert "Protects against multiple connects"
Browse files Browse the repository at this point in the history
This reverts commit f0f3e48.
  • Loading branch information
Phil Strong committed Apr 19, 2016
1 parent f0f3e48 commit 3887a4a
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions lib/eventsource.js
Original file line number Diff line number Diff line change
Expand Up @@ -112,11 +112,7 @@ function EventSource(url, eventSourceInitDict) {
if (res.statusCode == 204) return self.close();
return
}
// protect against multiple connects
if (readyState === EventSource.OPEN) {
return;
}


readyState = EventSource.OPEN;
res.on('close', onConnectionClosed);
res.on('end', onConnectionClosed);
Expand Down

0 comments on commit 3887a4a

Please sign in to comment.