mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Add no extend native rule
This commit is contained in:
parent
f35a8151e0
commit
b034c01240
2 changed files with 2 additions and 7 deletions
|
@ -46,6 +46,7 @@ module.exports = {
|
||||||
],
|
],
|
||||||
'no-duplicate-imports': ['error'],
|
'no-duplicate-imports': ['error'],
|
||||||
'no-empty-function': ['error'],
|
'no-empty-function': ['error'],
|
||||||
|
'no-extend-native': ['error'],
|
||||||
'no-floating-decimal': ['error'],
|
'no-floating-decimal': ['error'],
|
||||||
'no-multi-spaces': ['error'],
|
'no-multi-spaces': ['error'],
|
||||||
'no-multiple-empty-lines': ['error', { 'max': 1 }],
|
'no-multiple-empty-lines': ['error', { 'max': 1 }],
|
||||||
|
|
|
@ -24,12 +24,6 @@ function fillTimeOfDay(select) {
|
||||||
}).join('');
|
}).join('');
|
||||||
}
|
}
|
||||||
|
|
||||||
Array.prototype.remove = function (from, to) {
|
|
||||||
const rest = this.slice((to || from) + 1 || this.length);
|
|
||||||
this.length = from < 0 ? this.length + from : from;
|
|
||||||
return this.push.apply(this, rest);
|
|
||||||
};
|
|
||||||
|
|
||||||
const ScheduledTaskPage = {
|
const ScheduledTaskPage = {
|
||||||
refreshScheduledTask: function (view) {
|
refreshScheduledTask: function (view) {
|
||||||
loading.show();
|
loading.show();
|
||||||
|
@ -143,7 +137,7 @@ const ScheduledTaskPage = {
|
||||||
loading.show();
|
loading.show();
|
||||||
const id = getParameterByName('id');
|
const id = getParameterByName('id');
|
||||||
ApiClient.getScheduledTask(id).then(function (task) {
|
ApiClient.getScheduledTask(id).then(function (task) {
|
||||||
task.Triggers.remove(index);
|
task.Triggers.splice(index, 1);
|
||||||
ApiClient.updateScheduledTaskTriggers(task.Id, task.Triggers).then(function () {
|
ApiClient.updateScheduledTaskTriggers(task.Id, task.Triggers).then(function () {
|
||||||
ScheduledTaskPage.refreshScheduledTask(view);
|
ScheduledTaskPage.refreshScheduledTask(view);
|
||||||
});
|
});
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue