adonis-websocket icon indicating copy to clipboard operation
adonis-websocket copied to clipboard

fix(Connection): switched topic with no subscriptions exception to a debug message

Open Flambe opened this issue 6 years ago • 1 comments

Proposed changes

I've replaced the error inside Connection.makeEventPacket to a debug message as this was blocking broadcasts from being sent when a socket connection was closed. As far as I can tell, this does not cause any breaking changes.

Types of changes

What types of changes does your code introduce?

  • [x] Bugfix (non-breaking change which fixes an issue)
  • [ ] New feature (non-breaking change which adds functionality)
  • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist

  • [x] I have read the CONTRIBUTING doc
  • [x] Lint and unit tests pass locally with my changes
  • [x] I have added tests that prove my fix is effective or that my feature works.
  • [ ] I have added necessary documentation (if appropriate)

Further comments

This solution is based off of the investigation here: https://github.com/adonisjs/adonis-websocket/issues/63#issuecomment-417140481

Fixes #63

Flambe avatar Jan 22 '20 16:01 Flambe

Coverage Status

Coverage remained the same at 93.703% when pulling 9629a0ed2d0eaaeefc57e5ab1e85f08bbd27d632 on intergral:develop into 69b31f42cb0c81c76076210a3d225252c5024504 on adonisjs:develop.

coveralls avatar Jan 22 '20 16:01 coveralls