Public Link folder errors look like an empty folder #876

Open
opened 2026-10-02 17:28:47 +00:00 by kayg · 0 comments
Owner

Evidence

  • apps/web/src/lib/files/PublicLinkPage.svelte:141-159 sets entries = [] for every failed folder-list request. It does not keep an error state.
  • PublicLinkPage.svelte:667-670 then renders “This folder is empty.” after the request fails.

Rule

Issue #869 and CLAUDE.md require real empty states and real error states. A failed request is not proof that a folder is empty.

Expected behaviour

Keep request failure separate from a successful empty list. Show a plain error and a Retry action. Show “This folder is empty” only after the server returns an empty list.

Test idea

For a public folder, return an empty list, a list with items, a 5xx response and a network failure. Check that only the successful empty response shows the empty state. Retry a failed request and return items.

## Evidence - `apps/web/src/lib/files/PublicLinkPage.svelte:141-159` sets `entries = []` for every failed folder-list request. It does not keep an error state. - `PublicLinkPage.svelte:667-670` then renders “This folder is empty.” after the request fails. ## Rule Issue #869 and CLAUDE.md require real empty states and real error states. A failed request is not proof that a folder is empty. ## Expected behaviour Keep request failure separate from a successful empty list. Show a plain error and a Retry action. Show “This folder is empty” only after the server returns an empty list. ## Test idea For a public folder, return an empty list, a list with items, a 5xx response and a network failure. Check that only the successful empty response shows the empty state. Retry a failed request and return items.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
kayg/calternal#876
No description provided.