When storing instances of a class, everything is converted to plain objects, but
if the storage adapter stored a reference to the constructor when keeping, it
could restore the instance when finding by calling the constructor or using the
prototype and object.create) with the object attributes.
When storing instances of a class, everything is converted to plain objects, but if the storage adapter stored a reference to the constructor when keeping, it could restore the instance when finding by calling the constructor or using the prototype and
object.create
) with the object attributes.see https://github.com/Amazebot/bbot/blob/master/src/adapters/mongo.ts
related #58