diff options
| author | Adam Soltys <[email protected]> | 2023-01-13 20:26:53 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2023-01-13 20:26:53 -0800 |
| commit | 277b921ab2a97ac170f980c3c916ab1488318f2f (patch) | |
| tree | af771877eb261c41aa158aef2dddf96fa40f653c /src/lib/invoice.js | |
| parent | e0671101e4b217ff891fad85482e5943aa5cf543 (diff) | |
| download | coinos-ui-277b921ab2a97ac170f980c3c916ab1488318f2f.tar.gz coinos-ui-277b921ab2a97ac170f980c3c916ab1488318f2f.zip | |
server redis migration
Diffstat (limited to 'src/lib/invoice.js')
| -rw-r--r-- | src/lib/invoice.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib/invoice.js b/src/lib/invoice.js index 79639d84..c81b4061 100644 --- a/src/lib/invoice.js +++ b/src/lib/invoice.js @@ -17,21 +17,21 @@ export default async ({ cookies, request, url }) => { request_id }; - let user = { username: form.get('username') }; + let user = { username: form.get('username'), currency: form.get('currency') }; - let { uuid } = await post('/invoice', { invoice, user }, auth(cookies)); + let { id } = await post('/invoice', { invoice, user }, auth(cookies)); if (request_id) { if (url.pathname.endsWith('tip')) { - throw redirect(307, `/send/${uuid}`); + throw redirect(307, `/send/${id}`); } throw redirect(307, `/${user.username}/request/${request_id}`); } if (invoice.prompt) { - throw redirect(307, `/invoice/${uuid}/tip`); + throw redirect(307, `/invoice/${id}/tip`); } else { - throw redirect(307, `/invoice/${uuid}`); + throw redirect(307, `/invoice/${id}`); } }; |
