mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-29 16:54:04 +02:00
Always replace requests in loader by non-GET requests
Fix issue that caused form submits to be aborted when there's already a pending autosubmit for the same url. fixes #9024
This commit is contained in:
parent
2541b0eba4
commit
7c7881659d
@ -74,11 +74,13 @@
|
|||||||
if (autorefresh) {
|
if (autorefresh) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
// ...ignore the new request if it is already pending with the same URL
|
// ... ignore the new request if it is already pending with the same URL. Only abort GETs, as those
|
||||||
if (this.requests[id].url === url) {
|
// are the only methods that are guaranteed to return the same value
|
||||||
|
if (this.requests[id].url === url && method === 'GET') {
|
||||||
this.icinga.logger.debug('Request to ', url, ' is already running for ', $target);
|
this.icinga.logger.debug('Request to ', url, ' is already running for ', $target);
|
||||||
return this.requests[id];
|
return this.requests[id];
|
||||||
}
|
}
|
||||||
|
|
||||||
// ...or abort the former request otherwise
|
// ...or abort the former request otherwise
|
||||||
this.icinga.logger.debug(
|
this.icinga.logger.debug(
|
||||||
'Aborting pending request loading ',
|
'Aborting pending request loading ',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user