mirror of https://github.com/zulip/zulip.git
Reply to the recipient instead of the sender if replying to my own personal
Previously, if hamlet wrote to iago, and then hit "r" on his own message, the form would prompt hamlet to reply to himself. Now, Humbug will DTRT and prefill the form with iago instead. (imported from commit cb3260d1d0bc89b184dac84ebf1e5642d0bc1606)
This commit is contained in:
parent
29a41d992e
commit
cd5b623cfd
|
@ -11,6 +11,7 @@
|
|||
<script type="text/javascript" src="/static/js/zephyr.js"></script>
|
||||
<script type="text/javascript">
|
||||
var initial_zephyr_json = {{ zephyr_json }};
|
||||
var username = "{{ user_profile.user.username }}";
|
||||
</script>
|
||||
|
||||
<div class="row-fluid">
|
||||
|
|
|
@ -146,7 +146,12 @@ $(document).keydown(function(event) {
|
|||
$("#new_zephyr").focus();
|
||||
$("#new_zephyr").select();
|
||||
} else { // No instance, must be a personal
|
||||
prepare_personal(parent.find("span.zephyr_sender").text());
|
||||
|
||||
var recipient = parent.find("span.zephyr_sender").text();
|
||||
if (recipient == username) { // that is, we sent the original message
|
||||
recipient = parent.find("span.zephyr_personal_recipient").text();
|
||||
}
|
||||
prepare_personal(recipient);
|
||||
$("#new_personal_zephyr").focus();
|
||||
$("#new_personal_zephyr").select();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue