Skip to content

fix(project): handle inaccessible customer in project get#1956

Merged
martin-helmich merged 1 commit into
masterfrom
fix/project-get-customer-permission-denied
Jun 30, 2026
Merged

fix(project): handle inaccessible customer in project get#1956
martin-helmich merged 1 commit into
masterfrom
fix/project-get-customer-permission-denied

Conversation

@martin-helmich

Copy link
Copy Markdown
Member

Summary

Fixes #1955.

When a user has access to a project but not the customer it belongs to, mw project get failed with a PermissionDenied error: the customer fetch was asserted to return 200, and the 403 threw before any project information could be rendered.

This change removes the assertion on the customer fetch and renders the Customer row conditionally — the full customer table when accessible, otherwise a graceful fallback showing just the customer ID (which is always present on the project response). The project's own details are now always displayed.

🤖 Generated with Claude Code

When a user has access to a project but not the customer it belongs to,
`mw project get` failed with a PermissionDenied error because the customer
fetch was asserted to return 200. Render the project gracefully instead,
falling back to displaying just the customer ID when the customer is not
accessible.

Fixes #1955

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@martin-helmich martin-helmich merged commit 203a95b into master Jun 30, 2026
11 checks passed
@martin-helmich martin-helmich deleted the fix/project-get-customer-permission-denied branch June 30, 2026 15:39
Sign up for free to 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.

mw project get throws PermissionDenied error when customer is not accessible

1 participant