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

Initialize session on setup #1451

Merged
merged 1 commit into from
Jun 8, 2018
Merged

Conversation

tribut
Copy link
Contributor

@tribut tribut commented May 26, 2018

This makes the plugin compatible with system.session.initialize = false which makes it possible to have no session cookie (for frontend users) while the admin login still works.

The change seems to work fine, but I'm pretty new to Grav and it is entirely possible that the initialization should happen somewhere in the login or form plugins. Any feedback appreciated.

This makes the plugin compatible with `system.session.initialize = false`
which makes it possible to have no session cookie (for frontend users)
while the admin login still works.
@rhukster rhukster requested a review from mahagr May 29, 2018 12:50
@mahagr
Copy link
Member

mahagr commented May 31, 2018

I think the fix itself is fine, though as session used to be opened very early (before plugins were initialized), some plugins may break if the system.session.initialize = false was used, which is why it is disabled as default.

You're firing the event very early, so changes of breaking anything (except for non-admin plugins) is very low.

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.

3 participants