mirror of
https://github.com/zulip/zulip.git
synced 2025-11-01 20:44:04 +00:00
js: Convert _.extend to spread syntax or Object.assign.
This is not always a behavior-preserving translation: _.extend mutates its first argument. However, the code does not always appear to have been written to expect that. Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
This commit is contained in:
committed by
Tim Abbott
parent
6f32ef749f
commit
dbffb2a614
@@ -80,7 +80,7 @@ const reported_errors = new Set();
|
||||
const last_report_attempt = new Map();
|
||||
|
||||
function report_error(msg, stack, opts) {
|
||||
opts = _.extend({show_ui_msg: false}, opts);
|
||||
opts = { show_ui_msg: false, ...opts };
|
||||
|
||||
if (stack === undefined) {
|
||||
stack = 'No stacktrace available';
|
||||
|
||||
Reference in New Issue
Block a user