Open fumito-ito opened 2 years ago
I found a few problems with this issue:
@zwu52 Any updates on this ? In my use case, I detect custom message type by appData
. But now, I cannot do it in test case because of this bug.
Hi @fumito-ito , apologies for missing the thread. Thanks for reporting & coming up with the fix. LGTM. I have pinged the owner for a final quick review & approval.
The SDK fix is merged, but it needs a fix from backend side as well to push this data to the client device.
filed an internal bug to track the backend issue : b/216496087
[REQUIRED] Step 1: Describe your environment
Swift Package Manager
iOS
[REQUIRED] Step 2: Describe the problem
In-App Messaging' message has
appData
property. But it looks alwaysnil
for test message.Steps to reproduce:
displayMessage(:displayDelegate:)
in1.
's App and run the App in Debug modemessageForDisplay.appData
in debug console. It showsnil
.Relevant Code:
There are two causes of this problem.
1.
FIRIAMFetchResponseParser
always ignoresappData
for test messagehttps://github.com/firebase/firebase-ios-sdk/blob/d28849cb12de765d013b7222123bd3b8ae8c4f0a/FirebaseInAppMessaging/Sources/Data/FIRIAMFetchResponseParser.m#L357-L367
In this code,
FIRIAMFetchResponseParser
looks ignoreappData
for test message.2. In-App Messaging's response does not contain
appData
property for test message.https://github.com/firebase/firebase-ios-sdk/blob/480178b0871217c5f4fd3dd3c3a309c78c1d5c4c/FirebaseInAppMessaging/Sources/Flows/FIRIAMMsgFetcherUsingRestful.m#L171-L173
I found that
appData
also does not be included inresponseDict
for test message. It looks happened every time for test message.