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

Only get id once. #74

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Only get id once. #74

wants to merge 1 commit into from

Conversation

justinlittman
Copy link
Contributor

No description provided.

@@ -33,6 +31,10 @@ def qfacet_selected?
config = helpers.facet_configuration_for_field(field_name)
helpers.search_state.filter(config).include?(item.qvalue)
end

def ul_id
@ul_id ||= "b-h-#{SecureRandom.alphanumeric(10)}"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where was this called more than one time?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ul_id is used in L2 and L12 of app/components/blacklight/hierarchy/facet_field_component.html.erb

Previously, SecureRandom.alphanumeric(10) was called in facet_field_component.html.erb and facet_field_component.rb

@ndushay
Copy link
Contributor

ndushay commented Nov 16, 2023

oh no failing tests

@justinlittman
Copy link
Contributor Author

Coveralls is broken. I'll make a separate PR to remove it.

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.

None yet

3 participants