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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃帹Clean up the next link parser #193

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

Conversation

bvanderlaan
Copy link

Per the TODO: Can we clean this up a bit? this change set cleans up
the code used to parse out the last value via the next link header.

In the current implementation we use substring, indexOf, and replace
which results in a bit of nesting and unclear code. This change set
updates that code to use Regular Expressions and named functions to
make the code more clear.

Tests were added to ensure hat this refactor didn't break anything

Per the TODO _Can we clean this up a bit?_ this change set cleans up
the code used to parse out the last value via the next link header.

In the current implementation we use substring, indexOf, and replace
which results in a bit of nesting and unclear code. This change set
updates that code to use Regular Expressions and named functions to
make the code more clear.

Tests were added to ensure hat this refactor didn't break anything
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

1 participant