From 261c45adad88af2180005cd28fa4c7eff556999a Mon Sep 17 00:00:00 2001 From: sostler Date: Sun, 25 Apr 2010 13:37:21 -0400 Subject: Reload chatroom when json.v exists and var Version is undefined or doesn't equal json.v --- static/js/pichat.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'static') diff --git a/static/js/pichat.js b/static/js/pichat.js index 74b959f..85fa398 100644 --- a/static/js/pichat.js +++ b/static/js/pichat.js @@ -352,7 +352,7 @@ function updateTopic(newTopic) { function refresh() { var onSuccess = function(json) { try { - if (typeof Version !== 'undefined' && Version != json.v) { + if (json.v && (typeof Version == 'undefined' || Version != json.v)) { location.reload(); } -- cgit v1.2.3-70-g09d2