similar story than commit
9cc4958f5a03dd130198a090472782a2664d5b8d
We cannot really assert anything about the state of me (the view) and
consorts if me.destroyed is true, just early return.
We can get here because this is a delayed task, i.e., async,
everything can happen in between triggering it and receiving the
actual callback, so guard!
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
url: `/nodes/${nodename}/${type}/${vmid}/snapshot`,
method: 'GET',
failure: function(response, opts) {
+ if (me.destroyed) return;
Proxmox.Utils.setErrorMask(view, response.htmlStatus);
me.load_task.delay(load_delay);
},
success: function(response, opts) {
+ if (me.destroyed) {
+ // this is in a delayed task, avoid dragons if view has
+ // been destroyed already and go home.
+ return;
+ }
Proxmox.Utils.setErrorMask(view, false);
var digest = 'invalid';
var idhash = {};