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

fix: add default receive and send parameter values for HTMXRequest #2145

Merged

Conversation

tompin82
Copy link
Contributor

I noticed there seemed to be an issue setting the apps request_class to HTMXRequest.

The CSRF middleware doesn't initialize the request_class with a send argument, which causes the HTMXRequest class to fail its initialization since it expects send to exist.

This PR simply adds the empty_receive and empty_send functions as default vaules, which is consistent with the signature in the request class it derives from.

@tompin82 tompin82 requested review from a team as code owners August 10, 2023 11:46
@github-actions
Copy link

Documentation preview will be available shortly at https://litestar-org.github.io/litestar-docs-preview/2145

@tompin82 tompin82 changed the title fix: add default receive and send parameter values fix: add default receive and send parameter values for HTMXRequest Aug 10, 2023
Copy link
Member

@cofin cofin left a comment

Choose a reason for hiding this comment

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

LGTM

@cofin
Copy link
Member

cofin commented Aug 12, 2023

@all-contirbutors add @tompin82 for code and bugs

@cofin cofin merged commit 48e0f07 into litestar-org:main Aug 12, 2023
18 checks passed
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.

None yet

2 participants