I am making some API Firebase calls (download some user specific data) in my app share extension but the user is not signed into Firebase (aka currentUser is ni
The existing answers did not fix it for me, but I did find this official FireBase documentation.
In summary, the fix was using the app groups capability with same identifier in the app and extension.
Then including the code:
do {
try Auth.auth().useUserAccessGroup("TEAMID.com.example.group1")
} catch let error as NSError {
print("Error changing user access group: %@", error)
}
In my tests the authenticated user has the same uid in the main app and the share extension.
HTH