Skip to content

fix: replace router.reload with location.reload#435

Open
MuraariK13052008 wants to merge 1 commit intohatnote:masterfrom
MuraariK13052008:fix/bug-06-router-reload
Open

fix: replace router.reload with location.reload#435
MuraariK13052008 wants to merge 1 commit intohatnote:masterfrom
MuraariK13052008:fix/bug-06-router-reload

Conversation

@MuraariK13052008
Copy link
Copy Markdown

What this fixes

After deleting a round, the page never refreshed — the deleted round remained visible in the UI even though it had been removed from the database.

Root cause

Line 194 of RoundEdit.vue calls router.reload() after a successful round deletion. Vue Router does not have a reload() method — this throws TypeError: router.reload is not a function at runtime. Because the error was thrown inside a .then() callback, it was silently swallowed and the page never refreshed.

Fix

Changed router.reload()location.reload(), which is the correct browser API for a full page reload. This is consistent with the exact same pattern already used in RoundInfo.vue for activateRound() and pauseRound().

Files changed

  • frontend/src/components/Round/RoundEdit.vue

How to verify

  1. Open any campaign with at least one round
  2. Delete a round using the delete action
  3. Confirm the page now refreshes automatically and the deleted round no longer appears

Relates to: T415578

Vue Router does not provide reload(). Using
location.reload() to properly refresh the page.
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.

1 participant