aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHakim El Hattab <hakim.elhattab@gmail.com>2012-07-04 14:42:27 -0400
committerHakim El Hattab <hakim.elhattab@gmail.com>2012-07-04 14:42:27 -0400
commita6969770bd669fef99d6a0a2f99643d622c036ca (patch)
tree2dd9edcc7cb88c500ab460bcded14ea7f8c24b8f
parent28ee78e7e4754b9c198ee71d14558e65ff6b71f6 (diff)
downloadperl-software-in-gnu-guix-a6969770bd669fef99d6a0a2f99643d622c036ca.tar
perl-software-in-gnu-guix-a6969770bd669fef99d6a0a2f99643d622c036ca.tar.gz
simplify query match
-rw-r--r--lib/slidenotes/client.js3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/slidenotes/client.js b/lib/slidenotes/client.js
index f594fb6..1aba8b8 100644
--- a/lib/slidenotes/client.js
+++ b/lib/slidenotes/client.js
@@ -1,7 +1,6 @@
(function() {
// don't emit events from inside the previews themselves
- var qs = window.location.href.split('?');
- if (qs.length > 1 && qs[1].match('receiver')) { return; }
+ if ( window.location.search.match( /receiver/gi ) ) { return; }
var socket = io.connect(window.location.origin);
var socketId = Math.random().toString().slice(2);