mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 21:43:21 +00:00
message_edit: Cleanup unnecessary 2-layer nesting.
This commit is contained in:
@@ -157,9 +157,11 @@ function edit_message (row, raw_content) {
|
||||
});
|
||||
}
|
||||
|
||||
if (page_params.realm_message_content_edit_limit_seconds > 0) {
|
||||
// add timer
|
||||
if (can_edit_content &&
|
||||
page_params.realm_message_content_edit_limit_seconds > 0) {
|
||||
var timer_row = row.find('.message_edit_countdown_timer');
|
||||
if (can_edit_content) { // Add a visual timer
|
||||
|
||||
// I believe these need to be defined outside the countdown_timer, since
|
||||
// row just refers to something like the currently selected message, and
|
||||
// can change out from under us
|
||||
@@ -192,7 +194,6 @@ function edit_message (row, raw_content) {
|
||||
}
|
||||
}, 1000);
|
||||
}
|
||||
}
|
||||
|
||||
var edit_row = row.find(".message_edit");
|
||||
if ((message.type === 'stream' && message.subject === compose.empty_topic_placeholder()) ||
|
||||
|
||||
Reference in New Issue
Block a user