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.
This commit is contained in:
Thomas Piccirello 2018-10-15 21:08:42 -04:00 committed by sledgehammer999
parent 80435bae7e
commit 93147e787b
No known key found for this signature in database
GPG key ID: 6E4A2D025B7CC9A2

View file

@ -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);
}
},