Skip to content

Generate a correct response for the voucher-already-paid case

Jean-Paul Calderone requested to merge cors-headers-for-already-paid into main

Previously payForVoucher threw an exception which only the fallback WAI exception handler would catch. The fallback handler generated non-descript 500 errors.

Now charge handles the exception from payForVoucher and re-throws a ServantError which Servant renders nicely into a correct response.

Merge request reports