-
-
Notifications
You must be signed in to change notification settings - Fork 221
ISession added #198
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
ISession added #198
Conversation
| public function render() | ||
| { | ||
| $useSession = $this->dispatched && session_status() === PHP_SESSION_ACTIVE; | ||
| $useSession = $this->dispatched && Debugger::getSession()->isActive(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe this file should be untouched (session_status() === PHP_SESSION_ACTIVE)?
|
Simply don't call |
|
@dg But This is my problem. I have fake session, but with v2.4 it doesn't work correctly because Tracy checks for |
|
Yes :-) |
|
@dg What about if I replace with ? |
|
It is needed for AJAX requests and redirects in bar. |
I run a CLI application in a debug mode (development, CI).
But Tracy v2.4 is starting a session automatically and itselfs: [1], [2].
I can't solve this by fake session object. When DI Container is initialized,
session_start()is called and I do nothing with it.So I've extracted
session_*code intoISessioninterface which should allow set custom ISession implementation. It is useful in a CLI when debug mode is enabled.https://forum.nette.org/cs/26250-pojdte-otestovat-nette-2-4-rc?p=3#p175951
http://zlml.cz/fix-compatibility-with-nette-2-4#comment-2740141135