CommonDialogs.addLabel: remove long unused parameters
This commit is contained in:
parent
cca84aedfd
commit
3887665bcb
|
@ -352,22 +352,17 @@ const CommonDialogs = {
|
||||||
dialog.show();
|
dialog.show();
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
addLabel: function(select, callback) {
|
addLabel: function() {
|
||||||
const caption = prompt(__("Please enter label caption:"), "");
|
const caption = prompt(__("Please enter label caption:"), "");
|
||||||
|
|
||||||
if (caption != undefined && caption.trim().length > 0) {
|
if (caption != undefined && caption.trim().length > 0) {
|
||||||
|
|
||||||
const query = {op: "pref-labels", method: "add", caption: caption.trim()};
|
const query = {op: "pref-labels", method: "add", caption: caption.trim()};
|
||||||
|
|
||||||
if (select)
|
|
||||||
Object.extend(query, {output: "select"});
|
|
||||||
|
|
||||||
Notify.progress("Loading, please wait...", true);
|
Notify.progress("Loading, please wait...", true);
|
||||||
|
|
||||||
xhrPost("backend.php", query, (transport) => {
|
xhrPost("backend.php", query, () => {
|
||||||
if (callback) {
|
if (dijit.byId("labelTree")) {
|
||||||
callback(transport);
|
|
||||||
} else if (App.isPrefs()) {
|
|
||||||
dijit.byId("labelTree").reload();
|
dijit.byId("labelTree").reload();
|
||||||
} else {
|
} else {
|
||||||
Feeds.reload();
|
Feeds.reload();
|
||||||
|
|
Loading…
Reference in New Issue