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

Investigate this error and fix it #4471

Closed
1 of 3 tasks
maxkadel opened this issue Oct 28, 2024 · 1 comment
Closed
1 of 3 tasks

Investigate this error and fix it #4471

maxkadel opened this issue Oct 28, 2024 · 1 comment
Assignees
Labels
maintenance Ticket related to maintenance that needs to be done

Comments

@maxkadel
Copy link
Contributor

What maintenance needs to be done?

When upgrading to Blacklight 8 we get the same failure in many tests. Investigate the error below and fix it in a way where it works in both Blacklight 7 and 8, if possible.

Level of urgency

  • High
  • Moderate
  • Low

Why is this maintenance needed?

When upgrading to Blacklight 8 we get the same failure in many tests:

Failure/Error: <%= render BookmarkButtonComponent.new(document: @document) if current_or_guest_user %>

ActionView::Template::Error:
  undefined method `name' for nil:NilClass

          @id = id || @action.fetch(:id, "#{@action.name}Link")
                                                   ^^^^^
./app/views/catalog/_previous_next_doc.html.erb:52:in `new'
./app/views/catalog/_previous_next_doc.html.erb:52:in `_app_views_catalog__previous_next_doc_html_erb__1551705124890848459_78220'
./app/views/catalog/show.html.erb:1:in `_app_views_catalog_show_html_erb___4223457651520574876_78200'
./lib/orangelight/middleware/invalid_parameter_handler.rb:16:in `call'
./spec/requests/request_spec.rb:386:in `block (3 levels) in <top (required)>'
------------------
--- Caused by: ---
NoMethodError:
  undefined method `name' for nil:NilClass
  
          @id = id || @action.fetch(:id, "#{@action.name}Link")
                                                   ^^^^^
  ./app/views/catalog/_previous_next_doc.html.erb:52:in `new'

Implementation notes, if any

There is another ticket to update the _previous_next_doc to use a component, see whether this resolves this issue.

@maxkadel maxkadel added the maintenance Ticket related to maintenance that needs to be done label Oct 28, 2024
@maxkadel maxkadel self-assigned this Oct 29, 2024
@maxkadel
Copy link
Contributor Author

Closed by #4484

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Ticket related to maintenance that needs to be done
Projects
None yet
Development

No branches or pull requests

1 participant