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

[5.4] Make RequestGuard Macroable #19569

Merged
merged 2 commits into from
Jun 12, 2017
Merged

[5.4] Make RequestGuard Macroable #19569

merged 2 commits into from
Jun 12, 2017

Conversation

hezhiying
Copy link
Contributor

for RequestGuard Class use Illuminate\Support\Traits\Macroable;
Similar to SessionGuard Class,Allows RequestGuard Class expansion Method.

use Illuminate\Support\Traits\Macroable;
@lucasmichot
Copy link
Contributor

Tests ?


class RequestGuard implements Guard
{
use GuardHelpers;
use GuardHelpers,Macroable;
Copy link
Contributor

Choose a reason for hiding this comment

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

Needs a space after the comma

Copy link
Contributor

Choose a reason for hiding this comment

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

psr-2 says There MUST be one use keyword per declaration

Copy link
Contributor

Choose a reason for hiding this comment

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

True @BrandonShar but in this case this is not a declaration.

Copy link
Contributor

Choose a reason for hiding this comment

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

doh, read too fast!

@ntzm
Copy link
Contributor

ntzm commented Jun 12, 2017

Could do with a better title for the PR!

@tillkruss tillkruss changed the title Create RequestGuard.php [5.4] Create RequestGuard.php Jun 12, 2017
@tillkruss tillkruss changed the title [5.4] Create RequestGuard.php [5.4] Make RequestGuard Macroable Jun 12, 2017
@hezhiying
Copy link
Contributor Author

Thank you, my English is not good, sorry. I am going to optimize the code tomorrow, I am now 1 o'clock now. I was doing api internal call need to expand some of the methods and found that not like SessionGuard, I Pull Request reasonable?

@taylorotwell taylorotwell merged commit 11fe874 into laravel:5.4 Jun 12, 2017
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.

5 participants