mirror of
https://github.com/fluencelabs/js-libp2p-websockets
synced 2025-05-12 17:47:26 +00:00
chore: release version v0.4.1
This commit is contained in:
parent
37798ee8ea
commit
4d528ba16d
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "libp2p-websockets",
|
||||
"version": "0.4.0",
|
||||
"version": "0.4.1",
|
||||
"description": "JavaScript implementation of the WebSockets module that libp2p uses and that implements the interface-transport spec",
|
||||
"main": "lib/index.js",
|
||||
"jsnext:main": "src/index.js",
|
||||
|
@ -1,7 +1,7 @@
|
||||
'use strict'
|
||||
|
||||
// const debug = require('debug')
|
||||
// const log = debug('libp2p:tcp')
|
||||
const debug = require('debug')
|
||||
const log = debug('libp2p:websockets')
|
||||
const SWS = require('simple-websocket')
|
||||
const mafmt = require('mafmt')
|
||||
|
||||
@ -61,7 +61,8 @@ function WebSockets () {
|
||||
|
||||
this.close = (callback) => {
|
||||
if (listeners.length === 0) {
|
||||
callback(new Error('there are no listeners'))
|
||||
log('Called close with no active listeners')
|
||||
return callback()
|
||||
}
|
||||
var count = 0
|
||||
listeners.forEach((listener) => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user