Unhandled Rejection (FirebaseError): Function Firestore.collection() cannot be called with an empty path. code example
Example: Unhandled Rejection (FirebaseError): Function Firestore.collection() cannot be called with an empty path.
Add condition if parameter exists
if (id) {
...
}