mirror of
https://github.com/zulip/zulip.git
synced 2025-11-13 18:36:36 +00:00
compose_state: Rename compost_state.recipient to be about PMs only.
The compose_state.recipient field was only actually the recipient for the message if it was a private_message_recipient (in the sense of other code); we store the stream in compose_state.stream instead. As a result, the name was quite confusing, resulting in the possibility of problematic correctness bugs where code assumes this field has a valid value for stream messages. Fix this by changing it to compose_state.private_message_recipient for clarity.
This commit is contained in:
@@ -212,7 +212,7 @@ exports.pm_recipient = {
|
||||
|
||||
expect: function (expected_value) {
|
||||
var displayed_recipients = casper.evaluate(function () {
|
||||
return compose_state.recipient();
|
||||
return compose_state.private_message_recipient();
|
||||
});
|
||||
casper.test.assertEquals(displayed_recipients, expected_value);
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user