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

[11.x] Allow passing bool to facade Http@preventStrayRequests() #53992

Merged
merged 2 commits into from
Dec 20, 2024

Conversation

cosmastech
Copy link
Contributor

@cosmastech cosmastech commented Dec 20, 2024

The Http facade's preventStrayRequests() doesn't match the underlying the Http Factory definition.

I was wondering why my tests were failing when I wrote \Http::preventStrayRequests(false) and realized that when PHPStorm + Laravel Idea jumps into the definition, it's not jumping into the facade definition, but instead the underlying class.

The workaround for this is to call \Http::allowStrayRequests(), but I figured I'd offer this PR as tribute to the facade gods.

@cosmastech cosmastech changed the title [11.x] Allow passing bool to Http@preventStrayRequests() [11.x] Allow passing bool to facade Http@preventStrayRequests() Dec 20, 2024
@taylorotwell taylorotwell merged commit fd225c8 into laravel:11.x Dec 20, 2024
38 checks passed
@cosmastech cosmastech deleted the patch-4 branch December 20, 2024 20:13
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