* Clean up transport subscriptions and packet buffer. * * @private
()
| 516 | * @private |
| 517 | */ |
| 518 | private cleanup(): void { |
| 519 | debug(class="st">"cleanup"); |
| 520 | |
| 521 | this.subs.forEach((subDestroy) => subDestroy()); |
| 522 | this.subs.length = 0; |
| 523 | |
| 524 | this.decoder.destroy(); |
| 525 | } |
| 526 | |
| 527 | /** |
| 528 | * Close the current socket. |