diff options
-rw-r--r-- | hints-for-embedded.js | 2 | ||||
-rw-r--r-- | stella.js | 4 | ||||
-rw-r--r-- | twittperator/pong.tw | 2 | ||||
-rw-r--r-- | zip-de-download.js | 2 |
4 files changed, 5 insertions, 5 deletions
diff --git a/hints-for-embedded.js b/hints-for-embedded.js index cf86b4e..061dd7c 100644 --- a/hints-for-embedded.js +++ b/hints-for-embedded.js @@ -201,7 +201,7 @@ let INFO = if (site) { for each (let [n, v] in info) { [n, v] = [String(n), String(v)]; - if (site.name && !site.name(n)) + if (site.name && !site.name.test(n)) continue; let m = n.match(site.value) || v.match(site.value); if (m) @@ -999,7 +999,7 @@ Thanks: } YouTubeUserChannelPlayer.getIDfromURL = function (url) let ([_, r] = url.match(/\/([^\/]+)($|[\?]+)/)) r; - YouTubeUserChannelPlayer.isVideoURL = function (url) /^https?:\/\/(www\.)?youtube\.com\/watch\?.+/(url); + YouTubeUserChannelPlayer.isVideoURL = function (url) /^https?:\/\/(www\.)?youtube\.com\/watch\?.+/.test(url); YouTubeUserChannelPlayer.prototype = { __proto__: YouTubePlayer.prototype, @@ -1798,7 +1798,7 @@ Thanks: return U.raiseNotSupportedPage(); let arg = args.literalArg; - let index = (/^\d+:/)(arg) && parseInt(arg, 10); + let index = /^\d+:/.test(arg) && parseInt(arg, 10); if (index > 0) arg = lastCompletions[index - 1].command; let url = self.player.has('makeURL', 'x') ? makeRelationURL(self.player, arg) : arg; diff --git a/twittperator/pong.tw b/twittperator/pong.tw index dae2e15..9f3f381 100644 --- a/twittperator/pong.tw +++ b/twittperator/pong.tw @@ -12,7 +12,7 @@ plugins.twittperator.ChirpUserStream.addListener( function onMsg (msg, raw) { function negi (pattern, reply) { - if (RegExp('^\\s*@' + screenName + '\\s+' + pattern + '\s*$')(msg.text.trim())) { + if (RegExp('^\\s*@' + screenName + '\\s+' + pattern + '\s*$').test(msg.text.trim())) { plugins.twittperator.Twitter.say('@' + msg.user.screen_name + ' ' + reply, msg.id_str); return true; } diff --git a/zip-de-download.js b/zip-de-download.js index 4a54c85..4d60266 100644 --- a/zip-de-download.js +++ b/zip-de-download.js @@ -186,7 +186,7 @@ let SITE_INFO = [ let links = Array.slice( content.document.querySelectorAll('a')).filter( - function (link) (link.href && extPattern(link.href))); + function (link) (link.href && extPattern.test(link.href))); let xs = {}; for each(let link in links){ |