We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f21911a commit cb8c324Copy full SHA for cb8c324
client.js
@@ -61,8 +61,12 @@ function Client (opts) {
61
self.destroyed = false
62
63
self._rtcConfig = opts.rtcConfig
64
- self._wrtc = opts.wrtc
65
self._getAnnounceOpts = opts.getAnnounceOpts
+ self._wrtc = opts.wrtc
66
+
67
+ // Support lazy 'wrtc' module initialization
68
+ // See: https://github.com/feross/webtorrent-hybrid/issues/46
69
+ if (typeof self._wrtc === 'function') self._wrtc = self._wrtc()
70
71
debug('new client %s', self.infoHash)
72
0 commit comments