819
you are viewing a single comment's thread
view the rest of the comments
[-] frezik@midwest.social 1 points 4 hours ago* (last edited 4 hours ago)

None of this has much to do with type safety at all. A dynamically typed language might have a Salt object that has a constructor that takes a base64 string. If its common uuid library doesn't output base64, then you can't use it directly.

Nor does a specific uuid library matter much. It just needs to be able to output base64 strings, which is an uncommon uuid encoding, but it's out there.

Nor does type safety prevent providing a sensible default implementation.

The crate uses phc strings, which store the salt together with the hashed password, so no, it can handle it all on its own.

There was just no thought into how components work together.

this post was submitted on 08 Jan 2025
819 points (98.1% liked)

Programmer Humor

19910 readers
2168 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS