Revert "fix: /catalogs/[catalogId] crash on null-metadata rows (null-safe artists + toggle default off)" - #1874
Conversation
…fault mi…" This reverts commit fcd86ef.
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Warning Review limit reached
Next review available in: 25 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (2)
✨ Finishing Touches🧪 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 |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 75f1039aef
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| .filter((name): name is string => !!name); | ||
| return names.length > 0 ? names.join(", ") : "—"; | ||
| if (!artists || artists.length === 0) return "—"; | ||
| return artists.map((artist) => artist.name).join(", "); |
There was a problem hiding this comment.
Preserve null-safe artist rendering
When /catalogs/[catalogId] renders a song whose API payload has artists: [null] (the fresh valuation-claimed catalog case from the reverted fix, and also implied by isCompleteSong defensively checking a?.name), this line dereferences artist.name and throws, taking the catalog view to the error boundary as soon as missing-info rows are shown. Please keep the optional/null filtering before joining artist names.
Useful? React with 👍 / 👎.
| // Default OFF so fresh valuation-claimed catalogs (rows with null metadata) | ||
| // are visible instead of appearing empty (chat#1867) | ||
| const [hideIncomplete, setHideIncomplete] = useState(false); | ||
| const [hideIncomplete, setHideIncomplete] = useState(true); |
There was a problem hiding this comment.
Show incomplete catalog rows by default
For newly valuation-claimed catalogs whose song rows are present but still missing metadata, isCompleteSong filters every row out while this state defaults to true; the summary can report songs found, but InsertCatalogSongsList receives an empty array and renders no table, making a non-empty catalog appear empty until the user finds the toggle. Defaulting this off avoids hiding the exact rows users need to inspect or complete.
Useful? React with 👍 / 👎.
Reverts #1868
Summary by cubic
Reverts the null-metadata fix and returns
/catalogs/[catalogId]to its previous behavior. Incomplete songs are hidden by default again, andformatArtistsassumes non-null artist entries; related null-safety tests are removed.Written for commit 75f1039. Summary will update on new commits.