From c2f2c991e3f82e4c7526db5ef14dd26ee9644b75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=B6ren=20Weber?= Date: Tue, 22 Feb 2022 08:48:21 +0100 Subject: [PATCH] variant: don't switch theme if custom gets reset #188 --- static/js/variant.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/static/js/variant.js b/static/js/variant.js index 0a088ea2dc..e35309769b 100644 --- a/static/js/variant.js +++ b/static/js/variant.js @@ -130,7 +130,9 @@ var variants = { window.localStorage.removeItem( 'customvariantbase' ); window.localStorage.removeItem( 'customvariant' ); this.removeCustomVariantOption(); - this.changeVariant( variantbase ); + if( this.getVariant() == variantbase ){ + this.changeVariant( variantbase ); + } } },