Problem
When creating reactions or comments with createNotificationActivity: true and passing custom data via the custom parameter, this custom data is not accessible/propagated to the resulting notification activities.
How I'm adding reactions/comments with custom data:
Adding a reaction:
feedController.addActivityReaction(
activityId: activityData.id,
request: AddReactionRequest(
type: 'like',
createNotificationActivity: true,
custom: {
'communityId': 123,
'communityName': 'My Community',
},
),
);
Adding a comment:
activityController.addComment(
request: ActivityAddCommentRequest(
activityId: activityId,
comment: 'Hello!',
createNotificationActivity: true,
custom: {
'communityId': 123,
'communityName': 'My Community',
},
),
);
Expected Behavior
The custom data passed to AddReactionRequest or ActivityAddCommentRequest should be accessible somewhere in the notification ActivityData object - either via:
activity.custom
activity.notificationContext?.trigger?.custom
activity.notificationContext?.reaction?.custom
- Or some other clearly documented property
Actual Behavior
The custom data appears to not be exposed anywhere in the notification activity. There's no clear way (or documented way) to retrieve the custom metadata that was passed when creating the reaction/comment.
Questions
- Is the custom data supposed to be passed through to the notification activity?
- If yes, where should I look for it in the
ActivityData object?
- If not, is this a feature request or a bug?
Environment
stream_feeds version: ^0.5.0
- Flutter version: >=3.29.2
- Dart SDK version: >=3.9.0 <4.0.0
Problem
When creating reactions or comments with
createNotificationActivity: trueand passing custom data via thecustomparameter, this custom data is not accessible/propagated to the resulting notification activities.How I'm adding reactions/comments with custom data:
Adding a reaction:
Adding a comment:
Expected Behavior
The custom data passed to
AddReactionRequestorActivityAddCommentRequestshould be accessible somewhere in the notificationActivityDataobject - either via:activity.customactivity.notificationContext?.trigger?.customactivity.notificationContext?.reaction?.customActual Behavior
The custom data appears to not be exposed anywhere in the notification activity. There's no clear way (or documented way) to retrieve the custom metadata that was passed when creating the reaction/comment.
Questions
ActivityDataobject?Environment
stream_feedsversion: ^0.5.0