Only delete cookies which are actually set
authorGergő Tisza <tgr.huwiki@gmail.com>
Fri, 22 Jan 2016 22:29:40 +0000 (14:29 -0800)
committerBryan Davis <bd808@wikimedia.org>
Fri, 22 Jan 2016 23:27:32 +0000 (16:27 -0700)
commit1ce684fcef1ee69ca0921c05081cae47f90939e5
tree044acb09df501ed2bb962ef7b1571ad057fab4c0
parent9aa53627a53aabec0273cecf45a86e77927ef406
Only delete cookies which are actually set

Some API clients seem to be confused by cookie deletion.
Prevent cookie deletion on the first leg of the API login sequence
(for a client with an empty cookie jar) by only emitting deletion
headers for cookies which are set in the current request.

Bug: T124252
Change-Id: I180e094ea32f951e22adab2ec87d16e5de7cef97
includes/session/CookieSessionProvider.php
tests/phpunit/includes/session/CookieSessionProviderTest.php