mirror of
https://github.com/zulip/zulip.git
synced 2025-11-12 18:06:44 +00:00
Fix 'undefined is not an object' traceback with update_active_status.
This seems to only happen with Firefox for some reason. We've had similar issues with other ajax endpoints, so this is probably not the long-term solution, but I'd like to get this traceback fixed now. (imported from commit aa552fb56882ae2c73e352c7baf9532a88c5cf0a)
This commit is contained in:
@@ -96,6 +96,13 @@ function focus_ping() {
|
||||
}
|
||||
|
||||
$.post('/json/update_active_status', {status: ACTIVE}, function (data) {
|
||||
if (data === undefined || data.presences === undefined) {
|
||||
// We sometimes receive no data even on successful
|
||||
// requests; we should figure out why but this will
|
||||
// prevent us from throwing errors until then
|
||||
return;
|
||||
}
|
||||
|
||||
user_info = {};
|
||||
|
||||
// Update Zephyr mirror activity warning
|
||||
|
||||
Reference in New Issue
Block a user