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

Replace deprecated URI.encode with URI.encode_www_form_component #2

Merged
merged 1 commit into from
Nov 16, 2022

Conversation

jscharf
Copy link
Collaborator

@jscharf jscharf commented Nov 15, 2022

Similar to ono#53

We need to update deprecated code in this repository as part of work to upgrade our application to Ruby 3.

URI.encode is obsolete and needs to be replaced.

I replaced it with encode_www_form_component to encode the query string instead.

You can read more about this on the page for the Rubocop lint rule about it https://www.rubydoc.info/gems/rubocop/RuboCop/Cop/Lint/UriEscapeUnescape

@jscharf jscharf requested a review from TheDro November 15, 2022 20:08
Copy link

@TheDro TheDro left a comment

Choose a reason for hiding this comment

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

LGTM

@andrewmarkle
Copy link
Collaborator

Tested on the review env it LGTM.

@jscharf jscharf changed the title Replace deprecated URI.encode with CGI.escape Replace deprecated URI.encode with URI.encode_www_form_component Nov 16, 2022
@jscharf jscharf merged commit a2ae131 into master Nov 16, 2022
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