Open LucyEgan opened 3 days ago
Each time .connect(....) is called there will be another disconnected, error listener from it doing .disconnect() on the previous connection.
.connect(....)
disconnected
error
.disconnect()
I'm pretty sure its related to this in ws.ts disconnect(
ws.ts disconnect(
await Promise.any([ this.requireStatus(ConnectionStatus.Disconnected), this.requireStatus(ConnectionStatus.Error), ]);
db.connect() db.connect() db.connect() db.connect() db.connect()
db.connect()
Willl product the above example
the number of disconnected and error listeners to be cleaned up once complete.
2.0.0-alpha.4 for linux on x86_64
1.0.0-beta.12
lucy.e@aspirecomps.co.uk
Describe the bug
Each time
.connect(....)
is called there will be anotherdisconnected
,error
listener from it doing.disconnect()
on the previous connection.I'm pretty sure its related to this in
ws.ts disconnect(
Steps to reproduce
db.connect()
db.connect()
db.connect()
db.connect()
db.connect()
Willl product the above example
Expected behaviour
the number of
disconnected
anderror
listeners to be cleaned up once complete.SurrealDB version
2.0.0-alpha.4 for linux on x86_64
SurrealDB.js version
1.0.0-beta.12
Contact Details
lucy.e@aspirecomps.co.uk
Is there an existing issue for this?
Code of Conduct