mirror of
https://github.com/zulip/zulip.git
synced 2025-11-06 15:03:34 +00:00
Iterate through an array without using 'in', remove extra spacing.
This corrects some additional bugs introduced in 9128ddd and a5f06bd identified by Keegan. We previously used "for i in"-style looping, which is sub-optimal. Move to a different style. We also had a weird spacing thing I introduced in a previous commit, which has now been fixed. (imported from commit 7334d8ee703564bedeb0ea939b0d64ad2d5fceba)
This commit is contained in:
@@ -228,7 +228,7 @@ function respond_to_zephyr() {
|
|||||||
} else if (zephyr.type === 'huddle') {
|
} else if (zephyr.type === 'huddle') {
|
||||||
$('#zephyr-type-tabs a[href="#personal-message"]').tab('show');
|
$('#zephyr-type-tabs a[href="#personal-message"]').tab('show');
|
||||||
recipient = '';
|
recipient = '';
|
||||||
for (i in zephyr.display_recipient) {
|
for (var i = 0; i < zephyr.display_recipient.length; i++) {
|
||||||
recipient += zephyr.display_recipient[i].name + ', ';
|
recipient += zephyr.display_recipient[i].name + ', ';
|
||||||
}
|
}
|
||||||
prepare_huddle(recipient);
|
prepare_huddle(recipient);
|
||||||
|
|||||||
Reference in New Issue
Block a user