Filedot Model Fix |verified| «Linux HOT»
const schema = new mongoose.Schema( // Use a custom getter/setter "file.name": type: String, alias: 'fileName' ); // Or use `toJSON` transform schema.set('toJSON', transform: (doc, ret) => if (ret['file.name']) ret.fileName = ret['file.name']; delete ret['file.name'];
Fixing the Filedot model requires a three-phase rollout: filedot model fix
Firestore does not allow dots in field names. Use this before writing: const schema = new mongoose