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.8] Add only method to Session #29107

Merged
merged 2 commits into from Jul 8, 2019
Merged

[5.8] Add only method to Session #29107

merged 2 commits into from Jul 8, 2019

Conversation

nicoeg
Copy link
Contributor

@nicoeg nicoeg commented Jul 8, 2019

I see a lot of use cases where you would only want to retrieve some values from the session store instead of all values.
I commonly use the Arr::only method combined with session()->all() when for example wanting to set data on window for the frontend.

I've targeted 5.9 as it adds a new method to the Session interface.

src/Illuminate/Session/Store.php Outdated Show resolved Hide resolved
src/Illuminate/Contracts/Session/Session.php Outdated Show resolved Hide resolved
@nicoeg nicoeg changed the base branch from master to 5.8 July 8, 2019 13:32
@nicoeg nicoeg changed the title [5.9] Add only method to Session [5.8] Add only method to Session Jul 8, 2019
@taylorotwell taylorotwell merged commit ec4178b into laravel:5.8 Jul 8, 2019
@nicoeg nicoeg deleted the session-only-method branch July 8, 2019 13:55
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

3 participants