0👍
getDownloadURL() returns a promise, not a string. You need to use the promise to get the URL asynchronously, as shown in the documentation.
...
.then(fileData => {
return fileData.ref.getDownloadURL();
})
.then(imageUrl => {
return firebaseApp
.database()
.ref("meetups")
.child(key)
.update({ imageUrl: imageUrl });
})
...
Source:stackexchange.com