1// encrypt age regardless of any other options. name and _id will be left unencrypted
2userSchema.plugin(encrypt, { encryptionKey: encKey, signingKey: sigKey, encryptedFields: ['age'] });
3
1// exclude age from encryption, still encrypt name. _id will also remain unencrypted
2userSchema.plugin(encrypt, { encryptionKey: encKey, signingKey: sigKey, excludeFromEncryption: ['age'] });
3