mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Don't assign variable when not required to do so.
This commit is contained in:
parent
e6d75f6844
commit
54577db8a4
@ -197,10 +197,9 @@ export default createWidget('header', {
|
|||||||
|
|
||||||
if (state.searchContextType !== contextType) {
|
if (state.searchContextType !== contextType) {
|
||||||
state.contextEnabled = undefined;
|
state.contextEnabled = undefined;
|
||||||
|
state.searchContextType = contextType;
|
||||||
}
|
}
|
||||||
|
|
||||||
state.searchContextType = contextType;
|
|
||||||
|
|
||||||
if (state.contextEnabled === undefined) {
|
if (state.contextEnabled === undefined) {
|
||||||
if (forceContextEnabled.includes(contextType)) {
|
if (forceContextEnabled.includes(contextType)) {
|
||||||
state.contextEnabled = true;
|
state.contextEnabled = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user