Closed djberg96 closed 4 years ago
We can ignore the Hakiri warning, it's a bug on their end.
I know you're just moving code from a different repo, but when I put on my non-ManageIQ more_core_extensions hat :tophat: I wonder if this should instead be one or more of:
String#to_uuid
String#format_uuid
Digest::UUID#from_string(string)
Digest::UUID#format(string)
@Fryguy Any thoughts?
I don't like the string patches, because to_uuid I would expect some kind of UUID object out the other side, not for it to be cleaned. Same with .from_string. .format is not bad, but I think .clean is clearer.
lib/more_core_extensions/core_ext/digest/uuid.rb
@Fryguy Look ok now?
@Fryguy Any concerns?
Since Rails 5.1+ gives us the Digest::UUID class, let's extend it with the
clean
method here. The eventual goal is to update the core Hardware class with this method, and remove miq-uuid from gems-pending.