diff options
author | Anton Harniakou <anton.harniakou@gmail.com> | 2019-06-17 11:26:12 +0300 |
---|---|---|
committer | Anton Harniakou <anton.harniakou@gmail.com> | 2019-06-17 11:26:12 +0300 |
commit | eca063f027fcc7f13df8852495de2b4585c9af48 (patch) | |
tree | d19174c63a2100e028a4d762b17ec3f100e3af89 | |
parent | 1481502747df07c64c2f0ded7691f5dfe5ee0118 (diff) |
Return server from server.listen for method chaining to work
-rw-r--r-- | lib/server.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/server.js b/lib/server.js index cc8bd88..953d6a1 100644 --- a/lib/server.js +++ b/lib/server.js @@ -19,7 +19,7 @@ function Server (torrent, opts = {}) { closed = false server.on('connection', onConnection) server.on('request', onRequest) - _listen.apply(server, args) + return _listen.apply(server, args) } server.close = cb => { |