Bradley Schaefer on Nostr: nprofile1q…x2r82 I’ve used conversion methods in the past and left the ...
nprofile1qy2hwumn8ghj7un9d3shjtnddaehgu3wwp6kyqpqkjn5y6evs5rkcelfzqk4vgrh75u8gdx48slx04hvhhc0chw90qds9x2r82 (nprofile…2r82) I’ve used conversion methods in the past and left the constructor alone.
module Header::Conversion
def Header(value)
# … much the same as your constructor
end
end
include Header::Conversion
Header(value) # => a Header or whatever
I don’t have any problem with your approach, other than wanting to try to eliminate nils wherever possible
module Header::Conversion
def Header(value)
# … much the same as your constructor
end
end
include Header::Conversion
Header(value) # => a Header or whatever
I don’t have any problem with your approach, other than wanting to try to eliminate nils wherever possible