mysql-binuuid-rails icon indicating copy to clipboard operation
mysql-binuuid-rails copied to clipboard

Move unpack to deserialize

Open joel opened this issue 2 years ago • 0 comments

We need to unpack the binary when AR reads it from the database. That is the purpose of the method deserialize. That way, the cast method does not need to guess in which context it is called. That makes your code more straightforward to reason about.

joel avatar Dec 07 '23 08:12 joel