From e73e3d1bace89021bef8164f333476dca0d6270e Mon Sep 17 00:00:00 2001 From: Jessica McKellar Date: Wed, 18 Sep 2013 13:57:38 -0400 Subject: [PATCH] Don't error out on a name change for a stream you're not on. (imported from commit 8438087b3b6c66f41b9d9152661a93f01a086b28) --- static/js/subs.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/static/js/subs.js b/static/js/subs.js index 5b2507a5d8..932c8b3dc4 100644 --- a/static/js/subs.js +++ b/static/js/subs.js @@ -120,6 +120,11 @@ function update_stream_notifications(sub, value) { } function update_stream_name(sub, new_name) { + if (sub === undefined) { + // This isn't a stream we know about, so ignore it. + return; + } + // Rename the stream internally. var old_name = sub.name; stream_data.delete_sub(old_name);