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

Rewrite Middleware without sinatra #16

Merged
merged 2 commits into from
Jul 26, 2024
Merged

Conversation

danbernier
Copy link
Contributor

No description provided.


super(app)
def call(env)
dup._call(env)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why dup?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because rack middleware isn't threadsafe, and ivars leak across threads.

@danbernier danbernier merged commit 943bdd9 into main Jul 26, 2024
5 of 6 checks passed
@danbernier danbernier deleted the middleware-wo-sinatra branch July 26, 2024 22:26
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

Successfully merging this pull request may close these issues.

2 participants