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

Give listeners and middleware access to the logger #168

Closed
3 tasks done
aoberoi opened this issue Apr 24, 2019 · 0 comments
Closed
3 tasks done

Give listeners and middleware access to the logger #168

aoberoi opened this issue Apr 24, 2019 · 0 comments
Labels
enhancement M-T: A feature request for new functionality

Comments

@aoberoi
Copy link
Contributor

aoberoi commented Apr 24, 2019

Description

When building a middleware (and to a lesser degree when building a listener), its very useful to be able to output debugging information. The app has already made its intentions about which logs are appropriate clear by setting a LogLevel, so it would be a shame for middleware to ignore that intentional choice and have to build its own implementation for filtering messages (like using an environment variable or taking an explicit choice during instantiation).

Instead, if we made logger an argument that all middleware and listeners could access, then it would be simple for any middleware to opt into using the logger.

Requirements (place an x in each of the [ ])

  • I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've searched for any related issues and avoided creating a duplicate issue.
@aoberoi aoberoi added the enhancement M-T: A feature request for new functionality label Apr 24, 2019
seratch added a commit to seratch/bolt-js that referenced this issue Dec 24, 2019
seratch added a commit to seratch/bolt-js that referenced this issue Dec 24, 2019
@seratch seratch closed this as completed in 6ea7a5a Feb 4, 2020
seratch added a commit that referenced this issue Feb 4, 2020
Fix #168 #354 Add `logger`, `client` to the list of args send through to listeners
seratch added a commit to seratch/bolt-js that referenced this issue Feb 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement M-T: A feature request for new functionality
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant