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

net-http: Allow symbol based hashes for headers #1750

Merged
merged 3 commits into from
Mar 22, 2024

Commits on Feb 7, 2024

  1. Allow symbol based hashes for headers

    These methods work fine with headers given as `Hash[Symbol, untyped]`. I noticed when I got some squiggly lines in some of my methods that I already know work. I also defined `headers` as a type alias rather than copy-pasting the same definition everywhere (I can undo this if not desired).
    
    I did `(Hash[String, untyped] | Hash[Symbol, untyped])` rather than `Hash[String | Symbol, untyped]` because hashes with mixed key types can allow name collisions which gives unexpected behavior.
    
    I also feel like we can do better than `untyped` for the values, but leaving it for now.
    ThisGuyCodes authored Feb 7, 2024
    Configuration menu
    Copy the full SHA
    21b7cf0 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    68c360a View commit details
    Browse the repository at this point in the history

Commits on Mar 22, 2024

  1. Configuration menu
    Copy the full SHA
    316b8ec View commit details
    Browse the repository at this point in the history