mirror of
https://github.com/zulip/zulip.git
synced 2025-11-02 13:03:29 +00:00
lint: Replace 'return undefined;' with 'return;'.
Also adds a custom rule to eslint. Since the recommended way of extending eslint is to create plugins as standalone npm packages, the separate rule is published as 'eslint-plugins-empty-returns'. Fixes #8669.
This commit is contained in:
committed by
showell
parent
7ce139a798
commit
b22e8dc2b7
@@ -174,7 +174,7 @@ function is_odd(i) { return i % 2 === 1; }
|
||||
assert.equal(gen.next(), undefined);
|
||||
|
||||
var undef = function () {
|
||||
return undefined;
|
||||
return;
|
||||
};
|
||||
|
||||
global.blueslip.error = function (msg) {
|
||||
@@ -315,7 +315,7 @@ function is_odd(i) { return i % 2 === 1; }
|
||||
|
||||
unread.num_unread_for_person = function (user_ids_string) {
|
||||
if (user_ids_string === 'unk') {
|
||||
return undefined;
|
||||
return;
|
||||
}
|
||||
|
||||
if (user_ids_string === 'read') {
|
||||
|
||||
Reference in New Issue
Block a user