From 92122e1b27f199e161193b309749df46abb28a99 Mon Sep 17 00:00:00 2001 From: Matthias Schmidt Date: Sun, 25 Sep 2016 12:47:25 +0200 Subject: [PATCH] Fix switching of like badge css classes --- wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Like/Handler.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Like/Handler.js b/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Like/Handler.js index 1083c0f061..9c91f4748a 100644 --- a/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Like/Handler.js +++ b/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Like/Handler.js @@ -261,6 +261,9 @@ define( else { elShow(data.badge); + // remove old classes + data.badge.classList.remove('likeCounterLiked', 'likeCounterDisliked'); + // update like counter var cumulativeLikes = data.likes - data.dislikes; var content = ''; -- 2.20.1