mirror of https://github.com/zulip/zulip.git
stream_edit: Don't set undefined text for email address.
`sub.email_address` can be `undefined`, `$foo.text(undefined)` has no effect (it doesn't clear the text), and `text()` doesn't formally accept `undefined`, so here we only call `text()` if the new value isn't undefined.
This commit is contained in:
parent
924ebee421
commit
e739e9ae29
|
@ -109,7 +109,9 @@ export function open_edit_panel_empty() {
|
|||
|
||||
export function update_stream_name(sub, new_name) {
|
||||
const $edit_container = stream_settings_containers.get_edit_container(sub);
|
||||
if (sub.email_address !== undefined) {
|
||||
$edit_container.find(".email-address").text(sub.email_address);
|
||||
}
|
||||
$edit_container.find(".sub-stream-name").text(new_name);
|
||||
|
||||
const active_data = stream_settings_components.get_active_data();
|
||||
|
|
Loading…
Reference in New Issue