import * as t from "immutable";
import { getStateName as p } from "./getStateName.js";
const u = (e, n, i) => {
  const o = Object.keys(n);
  if (!o.length)
    return "Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are reducers.";
  const a = p(i);
  if (t.isImmutable ? !t.isImmutable(e) : !t.isCollection(e))
    return "The " + a + ' is of unexpected type. Expected argument to be an instance of Immutable.Collection or Immutable.Record with the following properties: "' + o.join('", "') + '".';
  if (t.isMap(e)) {
    const r = e.filter(
      (m, s) => !Object.prototype.hasOwnProperty.call(n, s)
    );
    if (r.size > 0)
      return "Unexpected " + (r.size === 1 ? "property" : "properties") + ' "' + [r.keys()].join('", "') + '" found in ' + a + '. Expected to find one of the known reducer property names instead: "' + o.join('", "') + '". Unexpected properties will be ignored.';
  }
  return null;
};
export {
  u as getUnexpectedInvocationParameterMessage
};
