import { t as trpc } from './trpc-client-Bucti7HD.js';
import { r as redirect } from './index-Djsj11qr.js';
import '@trpc/client';

const load = async ({ params }) => {
  const agent = params.agent;
  let agents = [];
  try {
    agents = await trpc.agents.list.query();
  } catch (e) {
    console.error(e);
  }
  if (!agents.includes(agent)) {
    throw redirect(307, "/tests");
  }
  return {};
};

var _page_ts = /*#__PURE__*/Object.freeze({
  __proto__: null,
  load: load
});

const index = 6;
let component_cache;
const component = async () => component_cache ??= (await import('./_page.svelte-repDo56A.js')).default;
const universal_id = "src/routes/tests/[agent]/+page.ts";
const imports = ["_app/immutable/nodes/6.BvZ1h4wy.js","_app/immutable/chunks/BEJ5fU19.js","_app/immutable/chunks/hp4PFHFv.js","_app/immutable/chunks/BUApaBEI.js","_app/immutable/chunks/CWj6FrbW.js","_app/immutable/chunks/CwfCwap7.js","_app/immutable/chunks/DhlfkVbH.js","_app/immutable/chunks/s_ghFM5S.js","_app/immutable/chunks/OmU4KyH2.js","_app/immutable/chunks/Chh6QAMO.js","_app/immutable/chunks/BvHT2aoj.js","_app/immutable/chunks/BzCf-tSc.js","_app/immutable/chunks/Dq371d_P.js","_app/immutable/chunks/LHqX4dNn.js","_app/immutable/chunks/C1FmrZbK.js","_app/immutable/chunks/BFwtWT9F.js","_app/immutable/chunks/DasC4_ox.js","_app/immutable/chunks/C1SoIhRp.js","_app/immutable/chunks/Kz6TiXE5.js","_app/immutable/chunks/84_D9GGU.js","_app/immutable/chunks/DVdtIo_d.js","_app/immutable/chunks/beLKjDF5.js","_app/immutable/chunks/B4NkqkLQ.js"];
const stylesheets = ["_app/immutable/assets/Link.D7uHGZ0C.css","_app/immutable/assets/Tab.DrtF13Tg.css","_app/immutable/assets/AgentSidebar.BEG0l2mN.css","_app/immutable/assets/6.Bsj2Wn1S.css"];
const fonts = [];

export { component, fonts, imports, index, stylesheets, _page_ts as universal, universal_id };
//# sourceMappingURL=6-P9PPYNxI.js.map
