updated check if needs to check name function

This commit is contained in:
Jack 2020-07-11 17:21:34 +01:00
parent d1bfc564f5
commit 677702eee1

View file

@ -146,7 +146,11 @@ exports.checkIfNeedsToChangeName = functions.https.onCall(
.doc(request.uid)
.get()
.then((doc) => {
if (doc.data().name === undefined) {
if (
doc.data().name === undefined ||
doc.data().name === null ||
doc.data().name === ""
) {
return admin
.auth()
.getUser(request.uid)