Added a check for any URL param. If found, strips them out before

going ahead with realtime timeline update.
This commit is contained in:
Sarven Capadisli 2009-09-21 14:30:12 +00:00
parent c9bc390090
commit 13de845e95
1 changed files with 9 additions and 3 deletions

View File

@ -11,11 +11,17 @@ var MeteorUpdater = function()
Meteor.callbacks["process"] = function(data) {
var d = JSON.parse(data);
$user_url = $('address .url')[0].href+d['user']['screen_name'];
var user_url = $('address .url')[0].href+d['user']['screen_name'];
var wlh = window.location.href;
if (wlh.indexOf('?') > 0) {
wlh = wlh.slice(0, wlh.indexOf('?'))
}
if (timeline == 'public' ||
$user_url+'/all' == window.location.href ||
$user_url == window.location.href) {
user_url+'/all' == wlh ||
user_url == wlh) {
RealtimeUpdate.receive(d);
}