mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2026-03-04 03:05:47 +01:00
Refactor :open action.
This commit is contained in:
@@ -147,12 +147,8 @@ const Browser = Module("browser", {
|
|||||||
|
|
||||||
commands.add(["o[pen]"],
|
commands.add(["o[pen]"],
|
||||||
"Open one or more URLs in the current tab",
|
"Open one or more URLs in the current tab",
|
||||||
function (args) {
|
function (args) { dactyl.open(args[0] || "about:blank"); },
|
||||||
if (args[0])
|
{
|
||||||
dactyl.open(args[0]);
|
|
||||||
else
|
|
||||||
dactyl.open("about:blank");
|
|
||||||
}, {
|
|
||||||
completer: function (context) completion.url(context),
|
completer: function (context) completion.url(context),
|
||||||
domains: function (args) array.compact(dactyl.parseURLs(args[0] || "").map(
|
domains: function (args) array.compact(dactyl.parseURLs(args[0] || "").map(
|
||||||
function (url) util.getHost(url))),
|
function (url) util.getHost(url))),
|
||||||
|
|||||||
Reference in New Issue
Block a user