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

fix: index destroy #2466

Merged
merged 1 commit into from Feb 8, 2024
Merged

fix: index destroy #2466

merged 1 commit into from Feb 8, 2024

Conversation

Paul-Bob
Copy link
Contributor

@Paul-Bob Paul-Bob commented Feb 8, 2024

Description

Fixes a regression (broken index destroy action) introduced here #2436

params[:view] was passed as empty string "" and we were doing params[:view] || action_name.to_s which would result in empty string "" since:

irb(main):001> "" || "value"
=> ""

A resource with the view value as nil breaks fetching fields. This is fixed now and resource's view have the propper value

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works

Manual review steps

  1. Go to any resource's index
  2. Destroy any record

@Paul-Bob Paul-Bob added the Fix label Feb 8, 2024
@Paul-Bob Paul-Bob self-assigned this Feb 8, 2024
Copy link

codeclimate bot commented Feb 8, 2024

Code Climate has analyzed commit aca2d5c and detected 0 issues on this pull request.

View more on Code Climate.

@Paul-Bob Paul-Bob merged commit 2dc21f3 into main Feb 8, 2024
23 checks passed
@Paul-Bob Paul-Bob deleted the fix/index_destroy branch February 8, 2024 10:31
Copy link
Contributor

github-actions bot commented Feb 8, 2024

This PR has been merged into main. The functionality will be available in the next release.

Please check the release guide for more information.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants