create stream: Remove unnecessary call of `update_announce_stream_state`.

Function `update_announce_stream_state` is used to update announce-stream
checkbox. If stream is private announce-stream checkbox gets disabled
by this function.

There are unncessary calls to `update_announce_stream_state` fuction.
i.e. it is called
 - when user clicks on `copy-from-stream` link to toggle streams-list
 - when stream-checkboxes value is changed to copy subs from stream
 - when user-filter value is changed to search users
These events does not affect announce-stream value, therefore
there is no need to call this function to update it.
This commit is contained in:
Yashashvi Dave 2018-08-04 11:14:52 +05:30 committed by Tim Abbott
parent 7480c73d9f
commit 7b92b836a7
1 changed files with 0 additions and 3 deletions

View File

@ -292,7 +292,6 @@ exports.show_new_stream_modal = function () {
}
});
update_announce_stream_state();
e.preventDefault();
});
};
@ -331,7 +330,6 @@ exports.create_handlers_for_users = function (container) {
$('#stream-checkboxes').toggle();
$("#copy-from-stream-expand-collapse .toggle").toggleClass('fa-caret-right fa-caret-down');
e.preventDefault();
update_announce_stream_state();
});
// Search People or Streams
@ -370,7 +368,6 @@ exports.create_handlers_for_users = function (container) {
});
}());
update_announce_stream_state();
e.preventDefault();
});
};