From 0d14f1360cafc44f0ac92b7f039f845cc2c00c70 Mon Sep 17 00:00:00 2001 From: anekos Date: Mon, 20 Apr 2015 22:40:14 +0900 Subject: 正規表現パターンを少し厳密に --- google-exopen.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'google-exopen.js') diff --git a/google-exopen.js b/google-exopen.js index bb345b5..4c1644a 100644 --- a/google-exopen.js +++ b/google-exopen.js @@ -24,7 +24,7 @@ let PLUGIN_INFO = xml` } // クエリ部の抜き出し - var q = decodeURI(url.href).match(/q=(.*?)&/); + var q = decodeURI(url.href).match(/[?&]q=(.*?)&/); // コマンドの引数 // foo+bar+hogeの形で取得されるので'+'を' 'で置き換え var commandPram = q[1].replace(/\+/g,' '); -- cgit v1.2.3