diff options
author | Tim Starling <tstarling@wikimedia.org> | 2024-02-27 10:26:31 +1100 |
---|---|---|
committer | Tim Starling <tstarling@wikimedia.org> | 2024-02-27 03:31:14 +0000 |
commit | 52208ed471b4df50bd1e19b9ffe76bc2e16bf16f (patch) | |
tree | 1edd2ffa3f30a914b756424b334401574f4f2a79 | |
parent | d0f82ad2bda1de43ec66de6face7a748a776ce09 (diff) |
In RequestContext::setUser() also reset $this->skinNamewmf/1.42.0-wmf.19
Viewing a page which transcludes Special:Prefixindex leads to the
default skin being used for the main request, instead of the user's
skin, in a regression of a bug from 2023. Tracing shows that
OutputPage::setupOOUI() calls RequestContext::getSkinName(), and the
skin name is permanently cached.
So, reset the skin name when the user is reset. This is a simple partial
fix.
Bug: T336504
Change-Id: If630f337ba6fb2b889e657d49112b878c3ad5f83
(cherry picked from commit aa01c94b3da722464ab925e2f58f3cd7db5c1107)
-rw-r--r-- | includes/context/RequestContext.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/includes/context/RequestContext.php b/includes/context/RequestContext.php index bb5b66769003..f69b89bf96d8 100644 --- a/includes/context/RequestContext.php +++ b/includes/context/RequestContext.php @@ -364,6 +364,7 @@ class RequestContext implements IContextSource, MutableContext { // Invalidate cached user interface language and skin $this->lang = null; $this->skin = null; + $this->skinName = null; } /** @@ -394,6 +395,7 @@ class RequestContext implements IContextSource, MutableContext { // Invalidate cached user interface language and skin $this->lang = null; $this->skin = null; + $this->skinName = null; } /** |