1
0
mirror of https://github.com/Radarr/Radarr.git synced 2026-04-23 22:25:14 -04:00

Fixed: Back to top button is back

Fixed: Delete series in Firefox
This commit is contained in:
kayone
2013-10-10 18:29:18 -07:00
parent c926775719
commit 48c9e29eab
3 changed files with 24 additions and 40 deletions
+13 -16
View File
@@ -1,31 +1,28 @@
//try to add ajax data as query string to DELETE calls.
'use strict';
define(function () {
define(
[
'jquery'
], function ($) {
return function () {
var original = $.ajax;
var original = this.ajax;
this.ajax = function () {
$.ajax = function (xhr) {
var xhr = arguments[0];
//check if ajax call was made with data option
if (xhr && xhr.data && xhr.type === 'DELETE') {
if (!xhr.url.contains('?')) {
xhr.url = xhr.url + '?' + $.param(xhr.data);
if (xhr.url.contains('?')) {
xhr.url += '&';
}
else {
xhr.url = xhr.url + '&' + $.param(xhr.data);
xhr.url += '?';
}
xhr.url += $.param(xhr.data);
delete xhr.data;
}
if (xhr) {
xhr.headers = xhr.headers || {};
// xhr.headers.Authorization = window.NzbDrone.ApiKey;
}
return original.apply(this, arguments);
};
};
});
});