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

Add getIsWebRequest #15690

Merged
merged 6 commits into from
Sep 6, 2024
Merged

Add getIsWebRequest #15690

merged 6 commits into from
Sep 6, 2024

Conversation

timkelty
Copy link
Contributor

@timkelty timkelty commented Sep 6, 2024

Description

Companion to \yii\base\Request::getIsConsoleRequest.

Nothing that can't be done with an instanceof check or !Craft::$app->getRequest()->isConsoleRequest, but if feels awkward to have one and not the other, and can make your conditions more readable.

@timkelty timkelty changed the base branch from 5.x to 4.x September 6, 2024 13:51
@brandonkelly brandonkelly changed the base branch from 4.x to 4.13 September 6, 2024 16:49
@brandonkelly brandonkelly merged commit c18ab45 into 4.13 Sep 6, 2024
@brandonkelly brandonkelly deleted the feature/isWebRequest branch September 6, 2024 16:53
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