code: function formatMatchingConstraints(matchingConstraints) {
    let ret = {};
    if (typeof matchingConstraints === 'undefined' || matchingConstraints === null) {
      throw new TypeError('Constraints cannot be undefined or null');
    }
    if (!isPlainObject(matchingConstraints)) {
      ret.callbackId = matchingConstraints;
    } else {
      ret = Object.assign({}, matchingConstraints);
    }
    return ret;
  }
docs: Transforms various forms of matching constraints to a single standard object shape
  @param {string|RegExp|Object} matchingConstraints - the various forms of matching constraints
  accepted
  @returns {Object} - an object where each matching constraint is a property
  @private