Conversation
WalkthroughThis pull request adds support for a new 🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
ref https://linear.app/ghost/issue/BER-3533 - adds a `gift_redemption_event` to the member activity feed so that when a member redeems a gift subscription, their timeline shows a dedicated entry: > **🎁 Started paid subscription (Ultra) via gift** - the existing `gift_purchase_event` also adopts the new gift icon so both sides of a gift read consistently in the buyer's and redeemer's member pages
05e2cc3 to
9229f88
Compare
|
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@ghost/admin/app/helpers/parse-member-event.js`:
- Around line 276-279: The gift redemption branch uses event.data.tier_name
directly which can be undefined and produce "(undefined)" in the UI; update the
branch that handles event.type === 'gift_redemption_event' (where const tierName
= event.data.tier_name) to guard against missing/null values by using a fallback
string (e.g., "unknown tier" or omit the tier text) before constructing the
return message so the UI never shows "(undefined)". Ensure you reference the
existing symbol tierName (and the event.type === 'gift_redemption_event' branch)
when applying the change.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 3e9cdcaf-f1fa-467e-9008-0f5850501a7a
⛔ Files ignored due to path filters (1)
ghost/admin/public/assets/icons/event-gift.svgis excluded by!**/*.svg
📒 Files selected for processing (5)
ghost/admin/app/helpers/parse-member-event.jsghost/admin/app/utils/member-event-types.jsghost/admin/tests/unit/utils/member-event-types-test.jsghost/core/core/server/services/members/members-api/repositories/event-repository.jsghost/core/test/unit/server/services/members/members-api/repositories/event-repository.test.js
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #27459 +/- ##
==========================================
- Coverage 73.39% 73.38% -0.01%
==========================================
Files 1553 1553
Lines 125017 125074 +57
Branches 15094 15097 +3
==========================================
+ Hits 91751 91783 +32
- Misses 32242 32285 +43
+ Partials 1024 1006 -18
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
no issues Follow-up tweaks to #27459: - Scaled the gift event icon down so its footprint matches other event icons, and nudged it up 1px for better optical centering - Moved the tier name out of the action string into the info span so gift redemptions render as `Started paid subscription via gift (Bronze)` — matches the existing `subscription_event` pattern


ref https://linear.app/ghost/issue/BER-3533
gift_redemption_eventto the member activity feed so that when a member redeems a gift subscription, their timeline shows a dedicated entry:gift_purchase_eventalso adopts the new gift icon so both sides of a gift read consistently in the buyer's and redeemer's member pages