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

Autocomplete: Use URL helper instead of absolute_url_for #3564

Merged
merged 1 commit into from
Nov 15, 2024

Conversation

csutter
Copy link
Contributor

@csutter csutter commented Nov 14, 2024

This uses Rails's standard URL helper instead of the custom one in the app to establish the absolute URL for the autocomplete endpoint.

@govuk-ci govuk-ci temporarily deployed to finder-frontend-pr-3564 November 14, 2024 16:58 Inactive
@csutter csutter marked this pull request as ready for review November 14, 2024 17:09
This uses Rails's standard URL helper instead of the custom one in the
app to establish the absolute URL for the autocomplete endpoint.
@govuk-ci govuk-ci temporarily deployed to finder-frontend-pr-3564 November 14, 2024 17:13 Inactive
Copy link
Member

@kevindew kevindew left a comment

Choose a reason for hiding this comment

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

Nice one 👍

Based off what we found I'll just leave a comment for prosperity that if we find there's a problem with this (edge case we didn't consider with proxy headers) we could resolve the quoted string problem with: absolute_url_for(api_search_autocomplete_path(format: :json)).to_s

@csutter csutter merged commit e2ee639 into main Nov 15, 2024
12 checks passed
@csutter csutter deleted the autocomp-use-url branch November 15, 2024 09:10
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.

3 participants