lib/mock/query-collection.js
function setDeepProperty (obj, propName, propValue) {
  propName = propName.split(".");
  for (let i = 0; i < propName.length - 1; i++) {
    obj = obj[propName[i]] = obj[propName[i]] || {};
  }
  obj[propName[propName.length - 1]] = propValue;
}
function setDeepProperty (obj, propName, propValue) {
  propName = propName.split(".");
  for (let i = 0; i < propName.length - 1; i++) {
    obj = obj[propName[i]] = obj[propName[i]] || {};
  }
  obj[propName[propName.length - 1]] = propValue;
}
function setDeepProperty ( obj , propName , propValue ) { propName = propName . split ( "." ) ; for ( let i = 0 ; i < propName . length - 1 ; i ++ ) { obj = obj [ propName [ i ] ] = obj [ propName [ i ] ] || { } ; } obj [ propName [ propName . length - 1 ] ] = propValue ; }
Sets a deep property of the given object.

@param   {object}    obj       - The object whose property is to be set.
@param   {string}    propName  - The deep property name (e.g. "Vet.Address.State")
@param   {*}         propValue - The value to set
Sets a deep property of the given object .