summaryrefslogtreecommitdiff
path: root/static/js
diff options
context:
space:
mode:
Diffstat (limited to 'static/js')
-rw-r--r--static/js/pichat.js5
1 files changed, 2 insertions, 3 deletions
diff --git a/static/js/pichat.js b/static/js/pichat.js
index e2ab061..93e2f05 100644
--- a/static/js/pichat.js
+++ b/static/js/pichat.js
@@ -74,9 +74,8 @@ function linkify(text) {
// durty hack to use a global to check this... but otherwise i'd have to rewrite the String.replace function? :/
var LastMsgContainsImage = false
function linkReplace(url) {
- //var urlWithoutParams = url.replace(/\?.*$/i, "");
-
- if (url.indexOf('http://') == 0 || url.indexOf('https://') == 0 || url.indexOf('ftp://') == 0)
+ var lowerurl = url.toLowerCase();
+ if (lowerurl.indexOf('http://') == 0 || lowerurl.indexOf('https://') == 0 || lowerurl.indexOf('ftp://') == 0)
linkUrl = url;
else
linkUrl = 'http://' + url;