pad_editbar: Call the callback after all work is done

pull/5152/head
Richard Hansen 2021-07-15 18:24:36 -04:00
parent a1b924f746
commit 07e05a92eb
1 changed files with 1 additions and 5 deletions

View File

@ -225,8 +225,6 @@ exports.padeditbar = {
module.removeClass('popup-show'); module.removeClass('popup-show');
} }
} }
if (cb) return cb();
} else { } else {
// hide all modules that are not selected and remove highlighting // hide all modules that are not selected and remove highlighting
// respectively add highlighting to the corresponding button // respectively add highlighting to the corresponding button
@ -239,12 +237,10 @@ exports.padeditbar = {
} else if (thisModuleName === moduleName) { } else if (thisModuleName === moduleName) {
$(`li[data-key=${thisModuleName}] > a`).addClass('selected'); $(`li[data-key=${thisModuleName}] > a`).addClass('selected');
module.addClass('popup-show'); module.addClass('popup-show');
if (cb) {
cb();
}
} }
} }
} }
if (cb) cb();
}, },
setSyncStatus: (status) => { setSyncStatus: (status) => {
if (status === 'syncing') { if (status === 'syncing') {