cloneObj = (obj, deepCopy = true) => {
  return deepCopy ? JSON.parse(JSON.stringify(obj)) : Object.assign({}, obj)
}
Clone an object as a shallow or deep copy.

@param {*} obj Object to clone
@param {Boolean} deepCopy Create a shallow (false) or deep copy (true)
@deprecated Use `cloneObject` (shallow copy) or `deepClone` (deep copy).