wallet-core: adjust to breaking merchant API change

This commit is contained in:
Florian Dold 2023-04-25 23:58:12 +02:00
parent fd86791e42
commit 0425b92dd7
No known key found for this signature in database
GPG Key ID: D2E4F00F29D02A4B

View File

@ -1553,7 +1553,10 @@ export async function processPurchasePay(
ws.http.postJson(payAgainUrl, reqBody),
);
logger.trace(`/paid response status: ${resp.status}`);
if (resp.status !== 204) {
if (
resp.status !== HttpStatusCode.NoContent &&
resp.status != HttpStatusCode.Ok
) {
throw TalerError.fromDetail(
TalerErrorCode.WALLET_UNEXPECTED_REQUEST_ERROR,
getHttpResponseErrorDetails(resp),