const d = /^.*?(?=\.query|\.path|\.headers|\.cookies|\.body)/, i = (t) => {
  if (t.startsWith("model"))
    return "models";
  if (t.includes(".")) {
    const e = t.match(d);
    if (e != null && e[0])
      return e[0];
  }
  return t;
}, o = (t, e) => {
  const n = i(t);
  return e.findIndex((r) => "tag" in r ? n.startsWith(r.id) : n === r.id);
};
export {
  o as getCurrentIndex
};
