Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[1.x] Fix API token deletion bug #155

Merged
merged 1 commit into from
Sep 11, 2020
Merged

[1.x] Fix API token deletion bug #155

merged 1 commit into from
Sep 11, 2020

Conversation

calebporzio
Copy link
Contributor

Fixes #152

Cause of the problem:

  • When a user views the permissions modal for an API Token, a property on the component called $managingPermissionsFor is set to the corresponding API Token model
  • If a user clicks "delete" and the model is no longer in the Database, that property hasn't been "unset", so when livewire goes to look it up by ID, it can't find it and a 404 error is thrown.

The Fix:

  • Immediately after deleting an API Token model, unset the $managingPermissionsFor property

@calebporzio calebporzio changed the title Fix API token deletion bug [1.x] Fix API token deletion bug Sep 11, 2020
@taylorotwell taylorotwell merged commit e3b191b into laravel:1.x Sep 11, 2020
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.

API Tokens modal with 404 error
2 participants