mirror of
https://github.com/zulip/zulip.git
synced 2025-11-16 11:52:01 +00:00
compose.js: Remove dead code from get_invalid_recipient_emails().
The piece of code is dead since there can be no instance where email === ''. This is ensured by util.extract_pm_recipients by filtering for empty strings in the pm_recipients list.
This commit is contained in:
@@ -396,10 +396,6 @@ exports.get_invalid_recipient_emails = function () {
|
|||||||
var private_recipients = util.extract_pm_recipients(compose_state.recipient());
|
var private_recipients = util.extract_pm_recipients(compose_state.recipient());
|
||||||
var invalid_recipients = [];
|
var invalid_recipients = [];
|
||||||
_.each(private_recipients, function (email) {
|
_.each(private_recipients, function (email) {
|
||||||
// This case occurs when compose_state.recipient() ends with ','
|
|
||||||
if (email === "") {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (people.realm_get(email) !== undefined) {
|
if (people.realm_get(email) !== undefined) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user