mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-01-31 17:05:45 +01:00
Fix executing commandline.input callback. Closes issue #331.
This commit is contained in:
@@ -520,8 +520,8 @@ var Bookmarks = Module("bookmarks", {
|
||||
commandline.input("This will delete all bookmarks. Would you like to continue? (yes/[no]) ",
|
||||
function (resp) {
|
||||
if (resp && resp.match(/^y(es)?$/i)) {
|
||||
Object.keys(bookmarkcache.bookmarks).forEach(function (id) { services.bookmarks.removeItem(id); });
|
||||
dactyl.echomsg("All bookmarks deleted", 1, commandline.FORCE_SINGLELINE);
|
||||
bookmarks.remove(Object.keys(bookmarkcache.bookmarks));
|
||||
dactyl.echomsg("All bookmarks deleted");
|
||||
}
|
||||
});
|
||||
else {
|
||||
@@ -534,8 +534,7 @@ var Bookmarks = Module("bookmarks", {
|
||||
var deletedCount = bookmarks.remove(context.allItems.items.map(function (item) item.item.id));
|
||||
}
|
||||
|
||||
dactyl.echomsg({ message: deletedCount + " bookmark(s) deleted" },
|
||||
1, commandline.FORCE_SINGLELINE);
|
||||
dactyl.echomsg({ message: deletedCount + " bookmark(s) deleted" });
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user