From 62b8b424cf98ffaf7d3e7f0087769deaef007864 Mon Sep 17 00:00:00 2001 From: Chris Adams Date: Fri, 24 May 2019 15:31:27 -0400 Subject: [PATCH] Suppress conflict warnings for failed reservations This is normal any time you open an asset someone else is working on. Closes #995 --- concordia/static/js/action-app/index.js | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/concordia/static/js/action-app/index.js b/concordia/static/js/action-app/index.js index 3f6e91314..89b9308b0 100644 --- a/concordia/static/js/action-app/index.js +++ b/concordia/static/js/action-app/index.js @@ -978,17 +978,21 @@ export class ActionApp { this.updateViewer(); }) .fail((jqXHR, textStatus, errorThrown) => { - console.error( - 'Unable to reserve asset: %s %s', - textStatus, - errorThrown - ); + if (jqXHR.status != 409) { + console.error( + 'Unable to reserve asset: %s %s', + textStatus, + errorThrown + ); - this.reportError( - 'reservation', - `Unable to reserve asset`, - errorThrown ? `${textStatus}: ${errorThrown}` : textStatus - ); + this.reportError( + 'reservation', + `Unable to reserve asset`, + errorThrown + ? `${textStatus}: ${errorThrown}` + : textStatus + ); + } this.assetReserved = false; this.updateViewer();