4strid / nekodb

Tiny ODM for MongoDB/NeDB

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Can't make an optional reference

4strid opened this issue · comments

Currently you can't mix references and basic types, so [ReferencedModel, null] won't work the way you might expect. Not really sure how to accomplish this, but if it's necessary I'm sure I can find a way.

I don't think it's a good idea to have an optional reference in your schema.