Skip to content

Commit

Permalink
Update toggle-column.blade.php
Browse files Browse the repository at this point in the history
  • Loading branch information
danharrin committed Dec 4, 2023
1 parent 8aab860 commit d6db8f9
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,17 @@
isLoading = true
const response = await $wire.updateTableColumnState(@js($getName()), @js($recordKey), updatedState)
const response = await $wire.updateTableColumnState(
@js($getName()),
@js($recordKey),
updatedState,
)
error = response?.error ?? undefined
// The state is only updated on the frontend if the toggle is
// being turned off, so we only need to reset it then.
if ((! state) && error) {
if (! state && error) {
state = ! state
}
Expand Down

0 comments on commit d6db8f9

Please sign in to comment.