checking if the session key exists before deleting it #53

wants to merge 1 commit into


None yet

2 participants


The session variables (for example 'state' and 'code') are not always saved yet in the session when trying to delete it.

In some use cases (such as the session manager in zend framework 2), the session is overriden by an arrayaccess object, causing a notice to be thrown when attempting to unset an un existing session variable.

This commit adds an "isset" check before the "unset".


I just figured out you will not merge this pull request without me signing a CLA (if at all), so since this is a really small change, can someone else that already signed the CLA please create a pull request with this change, and I'll close mine ?
I don't really care who adds this code, I just want it added, so my code and the code of all the other users that got stuck by what this PR tries to fix will work.

Just please make this change if you believe it fixes what I said, I will not have anything to ask and/or complain about it.


@dorongutman dorongutman reopened this Dec 27, 2012

Sorry it took so long to respond to this. Can you sign the Contributor License Agreement?

Once that's done we can look at merging this. Thanks for your contribution. If you don't want to sign it, we can fix this with a separate commit.


@gfosco indeed it took a while :-)

I do not want to sign the CLA, so if you could fix it with a separate commit - that would be awesome.

It's nice seeing an official representative in this repository, thanks for that.

@gfosco gfosco referenced this pull request Oct 15, 2013

Check isset before unset #95


Thank you. This will be addressed with PR #95

@gfosco gfosco closed this Oct 15, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment