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

Allow access to server from WebSocket event handlers #25

Open
joshkel opened this issue Jun 28, 2023 · 0 comments
Open

Allow access to server from WebSocket event handlers #25

joshkel opened this issue Jun 28, 2023 · 0 comments

Comments

@joshkel
Copy link
Contributor

joshkel commented Jun 28, 2023

I'm looking for a way to access shared server state from hapi-plugin-websocket's lower-level event handlers (connect, disconnect, and error). For a normal request, I could access this via request.server.app, but that's not an option for these event handlers.

Can/should they be extended to, e.g., offer server or app within the PluginState object or as an additional parameter?

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

1 participant