We're trying to use firebase analytics in our ios app.
Default events seems to be logged with no problem.
5.1.0 - [Firebase/Analytics][I-ACS023072] Event logged. Event name, event params: screen_view (_vs)
However, only custom event is not logged with this log below.
5.1.0 - [Firebase/Analytics][I-ACS025018] Event not logged. Call +[FIRApp configure]: custom_event_name
I think configurating is following the document. We have two different project's plist for each targets to setting up development environment to use different Firebase projects based on build type or target.
guard let path = Bundle.main.path(forResource: googleServiceInfoPlist, ofType: "plist"),
let opts = FirebaseOptions(contentsOfFile: path) else {
fatalError("Couldn't load config file")
}
FirebaseApp.configure(options: opts)
I guessed multiple plists causes this problem at first, but there was no changes with a GoogleService-Info.plist
and calling FirebaseApp.configure()
.
Sending event's func is just like this.
private func sendToFirebase(_ event: Trackable) {
Analytics.logEvent(event.name, parameters: event.properties)
}
What are the possible causes?
Thank you.