Skip to content

fix: Sort direction toggle not working in listings overview#306

Merged
orangecoding merged 1 commit intoorangecoding:masterfrom
datenwurm:fix/listings-sort-direction
May 8, 2026
Merged

fix: Sort direction toggle not working in listings overview#306
orangecoding merged 1 commit intoorangecoding:masterfrom
datenwurm:fix/listings-sort-direction

Conversation

@datenwurm
Copy link
Copy Markdown
Contributor

Description

setSortDir reads sortDir directly inside the click handler, capturing a stale value from the render that created the handler. Rapid clicks or batched updates can drop or invert toggles.

Steps to Reproduce

  1. Click the sort toggle button in the listings overview twice.
  2. Observe that the actual sort direction only changes once.

Expected

Each click toggles ascdesc based on the latest state.

Actual

Toggle is computed from a stale closure value; updates can be lost.

@orangecoding orangecoding merged commit fe0a09f into orangecoding:master May 8, 2026
2 checks passed
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.

2 participants