Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please update websockets to 2.0.0. #54

Closed
Romick2005 opened this issue Jan 24, 2017 · 2 comments
Closed

Please update websockets to 2.0.0. #54

Romick2005 opened this issue Jan 24, 2017 · 2 comments

Comments

@Romick2005
Copy link

Can you please try to switch ws to 2.0.0-beta.1?

@aichholzer
Copy link

Please update.
There is something weird going on here with the current version of ws being used. It keeps throwing this error on incoming messages:

/node_modules/express-ws/node_modules/ws/lib/Receiver.js:306
if (mask != null && buf != null) bufferUtil.unmask(buf, mask);
TypeError: Cannot read property 'unmask' of undefined

the Receiver.js is doing this (line 11):

bufferUtil = require('./BufferUtil').BufferUtil

and BufferUtil.js does this:

try {
  module.exports = require('bufferutil');
} catch (e) {
  module.exports = require('./BufferUtil.fallback');
}

which results in the error since bufferutil.BufferUtil (as used in Receiver.js) does not exist.

This works as expected and the code is also doing the right thing in the latest ws version.

@HenningM
Copy link
Owner

Should be fixed in version 3.0.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants