Implementing custom serialisers for SwayDB