mirror of
https://github.com/zulip/zulip.git
synced 2025-11-06 15:03:34 +00:00
notifications: Compute link earlier in mix notifications code.
This should make it more obvious how to later add a feature to include a link for out-of-view-scroll-down notifications, should we ever want that.
This commit is contained in:
@@ -617,6 +617,9 @@ exports.notify_local_mixes = function (messages) {
|
|||||||
blueslip.warn('We did not expect messages sent by others to get here');
|
blueslip.warn('We did not expect messages sent by others to get here');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
var link_msg_id = message.id;
|
||||||
|
var link_class = "compose_notification_narrow_by_topic";
|
||||||
|
var link_text = "Narrow to " + get_message_header(message);
|
||||||
|
|
||||||
var reason = exports.get_local_notify_mix_reason(message);
|
var reason = exports.get_local_notify_mix_reason(message);
|
||||||
|
|
||||||
@@ -634,10 +637,6 @@ exports.notify_local_mixes = function (messages) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
var link_msg_id = message.id;
|
|
||||||
var link_class = "compose_notification_narrow_by_topic";
|
|
||||||
var link_text = "Narrow to " + get_message_header(message);
|
|
||||||
|
|
||||||
exports.notify_above_composebox(reason, link_class, link_msg_id, link_text);
|
exports.notify_above_composebox(reason, link_class, link_msg_id, link_text);
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user