I am using code almost exactly as per the Firebase docs, but for whatever reason my async function is not able to fulfil the promise and the .then() block is never triggered.