enummer
enummer copied to clipboard
Access and set the underlaying Integer
Is there a way to read and write the underlaying integer? I'd like to use enummer for my rails-based stuff but in my JSON API i'd like to just send the Int as it is without the automatic conversion.
I've tested what I need for setting Int values here: https://github.com/MSchmidt/enummer/commit/487b538855f00cdf189489a872f479f63c60a42a
It just checks if the passed in value is already an integer and skips the casting.
Hey @MSchmidt. Thanks for the PR! I've unfortunately not had time to look at this yet, but it is on my todo list!