Skip to content

Commit

Permalink
Fix #4423: logic deciding when to ignore errors
Browse files Browse the repository at this point in the history
  • Loading branch information
avernet committed Feb 12, 2020
1 parent fcf3fa2 commit 3253c0e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion xforms/js/src/main/scala/org/orbeon/xforms/AjaxClient.scala
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,10 @@ object AjaxClient {
// Tell the loading indicator whether to display itself and what the progress message on the next Ajax request
Page.loadingIndicator.setNextConnectShow(showProgress)

asyncAjaxRequest(currentFormId, buildXmlRequest(currentFormId, events), ! (events exists (_.ignoreErrors)))
// Don't ignore errors if any of the events tell us not to ignore errors
// So we only ignore errors if all of the events tell us to ignore errors
val ignoreErrors = events.forall(_.ignoreErrors)
asyncAjaxRequest(currentFormId, buildXmlRequest(currentFormId, events), ignoreErrors)
}

// NOTE: Later we can switch this to an automatically-generated protocol
Expand Down

0 comments on commit 3253c0e

Please sign in to comment.