Move cookie-blocking methods to BlockManager
authorThalia <thalia.e.chan@googlemail.com>
Thu, 6 Jun 2019 18:00:20 +0000 (14:00 -0400)
committerThalia <thalia.e.chan@googlemail.com>
Tue, 11 Jun 2019 14:08:21 +0000 (15:08 +0100)
Move the cookie blocking logic into one place. Specifically, move
these methods to the BlockManager:
* User::trackBlockWithCookie
* DatabaseBlock::setCookie
* DatabaseBlock::clearCookie
* DatabaseBlock::getCookieValue
* DatabaseBlock::getIdFromCookieValue
* AbstractBlock::shouldTrackWithCookie

After this, BlockManager::trackBlockWithCookie should be called to
track a block, and BlockManager::clearBlockCookie should be called
to unset the cookie. The other methods in the above list are
helper methods that are made private or marked internal.

Also update places in core that call User::trackBlockWithCookie to
BlockManager::trackBlockWithCookie

Bug: T225141
Change-Id: I818962c6932c01c841a549a101637e00a7593e48


No differences found