mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-20 21:48:00 +01:00
Add helpInfo to the command-line handler, not that it makes a difference.
This commit is contained in:
@@ -39,7 +39,9 @@ CommandLineHandler.prototype = {
|
|||||||
catch (e) {
|
catch (e) {
|
||||||
dump(name + ": option '-" + name + "' requires an argument\n");
|
dump(name + ": option '-" + name + "' requires an argument\n");
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
|
|
||||||
|
helpInfo: " -" + name + " <opts>" + " Additonal options for " + appName + " startup\n".substr(name.length)
|
||||||
};
|
};
|
||||||
|
|
||||||
if (XPCOMUtils.generateNSGetFactory)
|
if (XPCOMUtils.generateNSGetFactory)
|
||||||
|
|||||||
@@ -111,23 +111,21 @@ const Bookmarks = Module("bookmarks", {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// returns number of deleted bookmarks
|
// returns number of deleted bookmarks
|
||||||
remove: function remove(url) {
|
remove: function remove(ids) {
|
||||||
try {
|
try {
|
||||||
if (isArray(url))
|
if (!isArray(ids)) {
|
||||||
var bmarks = url;
|
|
||||||
else {
|
|
||||||
let uri = util.newURI(url);
|
let uri = util.newURI(url);
|
||||||
var bmarks = services.get("bookmarks")
|
idw = services.get("bookmarks")
|
||||||
.getBookmarkIdsForURI(uri, {})
|
.getBookmarkIdsForURI(uri, {})
|
||||||
.filter(bookmarkcache.closure.isRegularBookmark);
|
.filter(bookmarkcache.closure.isRegularBookmark);
|
||||||
}
|
}
|
||||||
bmarks.forEach(function (id) {
|
ids.forEach(function (id) {
|
||||||
let bmark = bookmarkcache.bookmarks[id];
|
let bmark = bookmarkcache.bookmarks[id];
|
||||||
if (bmark)
|
if (bmark)
|
||||||
PlacesUtils.tagging.untagURI(util.newURI(bmark.url), null);
|
PlacesUtils.tagging.untagURI(util.newURI(bmark.url), null);
|
||||||
services.get("bookmarks").removeItem(id);
|
services.get("bookmarks").removeItem(id);
|
||||||
});
|
});
|
||||||
return bmarks.length;
|
return ids.length;
|
||||||
}
|
}
|
||||||
catch (e) {
|
catch (e) {
|
||||||
dactyl.reportError(e, true);
|
dactyl.reportError(e, true);
|
||||||
|
|||||||
Reference in New Issue
Block a user