From bab18036aa469a527efd2681d585278cd040e3c6 Mon Sep 17 00:00:00 2001 From: Thomas Piccirello Date: Mon, 15 Oct 2018 21:08:42 -0400 Subject: [PATCH] Fix WebUI Auto TMM context menu bug When multiple torrents are selected with different Auto TMM values, the Auto TMM context menu option is hidden. This option is never unhidden, requiring a refresh of the page. --- src/webui/www/private/scripts/contextmenu.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/webui/www/private/scripts/contextmenu.js b/src/webui/www/private/scripts/contextmenu.js index 25ebb59a0..2c26dc037 100644 --- a/src/webui/www/private/scripts/contextmenu.js +++ b/src/webui/www/private/scripts/contextmenu.js @@ -345,10 +345,13 @@ var TorrentsTableContextMenu = new Class({ else if (!there_are_paused && !there_are_force_start) this.hideItem('Start'); - if (!all_are_auto_tmm && there_are_auto_tmm) + if (!all_are_auto_tmm && there_are_auto_tmm) { this.hideItem('AutoTorrentManagement'); - else + } + else { + this.showItem('AutoTorrentManagement'); this.setItemChecked('AutoTorrentManagement', all_are_auto_tmm); + } },