I found that cbmongodb failed to reset nested document with two-level depth. Below is the example:
`
property name=“location” schema=true validate=“array”;
property name=“location.address” schema=true validate=“struct”;
property name=“location.address.street” schema=true validate=“string”;
property name=“location.address.city” schema=true validate=“string”;
`
Type: expression
Messages: cannot cast [address] string to a number value
Tag Context:
Template: C:\myproject\coldbox\system\modules\cbmongodb\models\BaseDocumentService.cfc LINE: 315:
316: //cf11 return empty not structure notation
317: var nested = structGet(sget);
318:
319: if(!isStruct(nested)){
Template: C:\myproject\coldbox\system\modules\cbmongodb\models\ActiveEntity.cfc LINE: 574: this.set_id(’’);
575: for(var prop in get_map()){
576: this.set(prop,this.getPropertyDefault(variables._map[prop]));
577: }
578: }
The document structure is produced correctly. It just the reset() is failing. Hopefully, Jon could verify and fix the issue. Thank you.