Skip to content

Commit

Permalink
Always remove entities with errors from queue
Browse files Browse the repository at this point in the history
  • Loading branch information
andig committed Oct 28, 2017
1 parent 3aeb2bf commit 353c070
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion htdocs/js/entities.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,10 @@ vz.entities.loadDetails = function() {
},
function(xhr) {
var exception = (xhr.responseJSON || {}).exception;
// remove problematic entity
vz.entities.splice(vz.entities.indexOf(entity), 1); // remove
// default error handling is skipped - be careful
if (exception && exception.message.match(/^Invalid UUID|^No entity/)) {
vz.entities.splice(vz.entities.indexOf(entity), 1); // remove
// return new resolved deferred
return $.Deferred().resolveWith(this, [xhr]);
}
Expand Down

0 comments on commit 353c070

Please sign in to comment.