import n from "./_baseFlatten.js";
import l from "./_baseOrderBy.js";
import p from "./_baseRest.js";
import o from "./_isIterateeCall.js";
var h = p(function(f, r) {
  if (f == null)
    return [];
  var m = r.length;
  return m > 1 && o(f, r[0], r[1]) ? r = [] : m > 2 && o(r[0], r[1], r[2]) && (r = [r[0]]), l(f, n(r), []);
});
export {
  h as default
};
