apply no-throw-literal

This commit is contained in:
pypy
2020-01-11 20:27:57 +09:00
parent 15eb9a45ac
commit 98f5448d52
2 changed files with 3 additions and 6 deletions
-1
View File
@@ -50,7 +50,6 @@ module.exports = {
'no-plusplus': 0, 'no-plusplus': 0,
'no-tabs': 0, 'no-tabs': 0,
'no-ternary': 0, 'no-ternary': 0,
'no-throw-literal': 0,
'no-undefined': 0, 'no-undefined': 0,
'no-underscore-dangle': 0, 'no-underscore-dangle': 0,
'no-var': 0, 'no-var': 0,
+3 -5
View File
@@ -423,16 +423,14 @@ if (window.CefSharp) {
if (extra !== undefined) { if (extra !== undefined) {
text.push(extra); text.push(extra);
} }
text = text.map((s) => escapeTag(s)).join('<br>');
if (text.length) { if (text.length) {
new Noty({ new Noty({
type: 'error', type: 'error',
text: text.map((s) => escapeTag(s)).join('<br>') text
}).show(); }).show();
} }
throw { throw new Error(text);
'status_code': code,
error
};
}; };
API.bulk = function (options) { API.bulk = function (options) {