Skip to content

Fall back gracefully when deployedRelative is null - #23

Merged
oBecks merged 1 commit into
masterfrom
claude/relaxed-chaum-60165b
Aug 28, 2026
Merged

Fall back gracefully when deployedRelative is null#23
oBecks merged 1 commit into
masterfrom
claude/relaxed-chaum-60165b

Conversation

@oBecks

@oBecksoBecks commented Aug 28, 2026

Copy link
Copy Markdown
Owner

User description

Summary

  • Hero.tsx and PetCard.tsx interpolated pet.deployedRelative directly into display strings, which would render the literal word "null" if a deployed pet's deployedRelative were ever null
  • No live code path produces that today (markDeployed always sets deployedAt, and toDashboardPet only computes deployedRelative when it's present), but the display sites shouldn't rely on that invariant holding
  • Added a fallback: Hero drops the relative-time clause, PetCard shows plain "Deployed" — behavior is unchanged when deployedRelative is present

Test plan

  • pnpm typecheck
  • pnpm lint
  • pnpm test (15/15 passing)

🤖 Generated with Claude Code


Generated description

Below is a concise technical summary of the changes proposed in this PR:
Update the dashboard Hero and PetCard components to gracefully display deployed pets when deployedRelative is null, avoiding the literal “null” text while preserving existing output when a relative time is available.

Latest Contributors(2)
UserCommitDate
beckomerrr@gmail.comFall back gracefully w...August 28, 2026
oBecksAdd Dashboard route wi...August 26, 2026
Review this PR on Baz | Customize your next review

Summary by CodeRabbit

  • Bug Fixes
    • Improved deployment status messaging when relative deployment timing is unavailable.
    • Deployed pets now show “Deployed” instead of an empty or undefined value.
    • Removed unnecessary trailing text from deployment phase descriptions.

Hero and PetCard interpolated pet.deployedRelative directly, which
would render the literal string "null" if a deployed pet ever lacked
deployedAt. No live path produces that today, but the display sites
should not depend on it holding.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@vercel

vercelBot commented Aug 28, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

ProjectDeploymentActionsUpdated (UTC)
commit-petReadyReadyPreviewAug 28, 2026 10:38am

@coderabbitai

coderabbitaiBot commented Aug 28, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 0c9e487a-090b-40fe-9c27-75fa751ff398

📥 Commits

Reviewing files that changed from the base of the PR and between 49348cb and e3439ef.

📒 Files selected for processing (2)
  • app/dashboard/_components/Hero.tsx
  • app/dashboard/_components/PetCard.tsx

Included review availability: Your plan provides up to 10 included reviews per hour; 5 remain after this review.


📝 Walkthrough

Walkthrough

The dashboard now omits missing relative deployment text in the deployed-phase message and displays Deployed for deployed pets without a relative deployment time.

Changes

Deployment status display

Layer / File(s)Summary
Deployment status rendering
app/dashboard/_components/Hero.tsx, app/dashboard/_components/PetCard.tsx
The deployed-phase message conditionally includes pet.deployedRelative. The pet card displays Deployed when that value is unavailable.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Merge Risk:⚪ Minimal · up to e3439

This change prevents deployed pets from displaying the literal “null” while preserving existing output when relative time is available. No actionable merge-blocking risk remains after normal checks and review.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check nameStatusExplanationResolution
Docstring Coverage⚠️ WarningDocstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 2 files.Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check nameStatusExplanation
Description Check✅ PassedCheck skipped - CodeRabbit’s high-level summary is enabled.
Title check✅ PassedThe title clearly and concisely describes the main change: graceful fallback handling when deployedRelative is null.
Linked Issues check✅ PassedCheck skipped because no linked issues were found for this pull request.
Out of Scope Changes check✅ PassedCheck skipped because no linked issues were found for this pull request.
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch claude/relaxed-chaum-60165b

Comment @coderabbitai help to get the list of available commands.

@oBecks
oBecks merged commit 629d2c9 into masterAug 28, 2026
6 checks passed
@oBecks
oBecks deleted the claude/relaxed-chaum-60165b branch August 28, 2026 10:43
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@oBecks