summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorMatthew Miller <matthew@millerti.me>2020-07-05 00:02:09 -0700
committerMatthew Miller <matthew@millerti.me>2020-07-05 00:02:09 -0700
commit1702b8cce97efdfc5b9510b2a75e38aa5b8f655f (patch)
tree68eeb6669126956cff9be529bd2611deca644a1f
parentc53ae60b66e2f176ad76694300f0e8cf112c02c2 (diff)
Use async in demo /verify-attestation
-rw-r--r--example/index.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/example/index.js b/example/index.js
index f8d7cc7..a8b8afa 100644
--- a/example/index.js
+++ b/example/index.js
@@ -146,7 +146,7 @@ app.get('/generate-attestation-options', (req, res) => {
);
});
-app.post('/verify-attestation', (req, res) => {
+app.post('/verify-attestation', async (req, res) => {
const { body } = req;
const user = inMemoryUserDeviceDB[loggedInUserId];
@@ -155,7 +155,7 @@ app.post('/verify-attestation', (req, res) => {
let verification;
try {
- verification = verifyAttestationResponse({
+ verification = await verifyAttestationResponse({
credential: body,
expectedChallenge,
expectedOrigin: origin,