Before this change the overridden helper method was not loading correctly and Blacklight's original implementation was executing causing the return value to be a SolrDocument which led to incorrect urls in the search results. This is probably due to a change in the way zeitwerk autoloading works in Rails 7.2 and only manifests in production environment. It doesn't appear in the development environment because of a reloading workaround that targets the development environment (see https://github.com/avalonmediasystem/avalon/pull/1747). This workaround also fixes the issue in production but it the change in this PR feels like a better solution for this specific problem as well as being more limited in scope.
Resolves #6124
Before this change the overridden helper method was not loading correctly and Blacklight's original implementation was executing causing the return value to be a SolrDocument which led to incorrect urls in the search results. This is probably due to a change in the way zeitwerk autoloading works in Rails 7.2 and only manifests in production environment. It doesn't appear in the development environment because of a reloading workaround that targets the development environment (see https://github.com/avalonmediasystem/avalon/pull/1747). This workaround also fixes the issue in production but it the change in this PR feels like a better solution for this specific problem as well as being more limited in scope.