From 1072c7a213baeace777d18b888eb43086afeb87e Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Tue, 23 Aug 2022 02:26:09 -0700 Subject: generate new invoice on tip --- src/lib/utils.js | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/lib/utils.js') diff --git a/src/lib/utils.js b/src/lib/utils.js index a1bdf8d7..65025c3a 100644 --- a/src/lib/utils.js +++ b/src/lib/utils.js @@ -47,6 +47,8 @@ export const put = (url, body, headers) => { method: 'PUT', body: JSON.stringify(body), headers + }).then(async (r) => { + if (!r.ok) throw new Error('put failed'); }); }; -- cgit v1.2.3