-
-
Notifications
You must be signed in to change notification settings - Fork 109
Open
Description
I currently have a schema definition like this:
const PeopleSchema = new SimpleSchema({
userId: { type: String },
interests: { type: Array, optional: true },
'interests.$': { type: String, optional: true },
});
If the interests field comes with values, it should save the array but if the interests field is an empty array, it should not store it in the database (remove the field completely). I do this with strings perfectly but I cant get it to work with Arrays. Does anyone know how I could do this?
Metadata
Metadata
Assignees
Labels
No labels