Skip to content

Add stable Accept preference ordering. - #117

Merged
samuel-williams-shopify merged 1 commit into
mainfrom
stable-accept-preferences
Aug 10, 2026
Merged

Add stable Accept preference ordering.#117
samuel-williams-shopify merged 1 commit into
mainfrom
stable-accept-preferences

Conversation

@samuel-williams-shopify

Copy link
Copy Markdown
Contributor

Summary.

  • Add Accept#preferred_media_ranges for ordering parsed media ranges by descending quality.
  • Preserve source order when quality factors are equal.
  • Keep Accept#media_ranges as the source-order parsing interface.

Verification.

  • bundle exec sus test/protocol/http/header/accept.rb: 21 tests, 61 assertions.
  • bundle exec sus: 764 tests, 1551 assertions.
  • RuboCop passes for the changed Ruby files.
  • git diff --check passes.

@samuel-williams-shopify
samuel-williams-shopify merged commit be361a9 into main Aug 10, 2026
34 of 40 checks passed
@samuel-williams-shopify
samuel-williams-shopify deleted the stable-accept-preferences branch August 10, 2026 00:20
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.

1 participant