From d987c1c50b30dcb651d32b6a86c2caff2ca50f84 Mon Sep 17 00:00:00 2001 From: derflocki Date: Fri, 1 Aug 2014 02:00:05 +0200 Subject: [PATCH] fixed root_domain regex, fixes #98 --- LAB.src.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/LAB.src.js b/LAB.src.js index 99807cd..71209e9 100644 --- a/LAB.src.js +++ b/LAB.src.js @@ -16,7 +16,7 @@ // stateless variables used across all $LAB instances root_page = /^[^?#]*\//.exec(location.href)[0], - root_domain = /^\w+\:\/\/\/?[^\/]+/.exec(root_page)[0], + root_domain = /^[a-z][\w\+-\/]+\:\/\/\/?[^\/]+/.exec(root_page)[0], append_to = document.head || document.getElementsByTagName("head"), // inferences... ick, but still necessary @@ -511,4 +511,4 @@ } })("addEventListener","DOMContentLoaded"); -})(this); \ No newline at end of file +})(this);