2023-12-20 17:23:31 -05:00
|
|
|
import { log } from "@server/logger";
|
|
|
|
|
2023-10-03 00:56:16 -04:00
|
|
|
export default eventHandler((ev) => {
|
|
|
|
let chapParam = getRouterParams(ev).chapter;
|
2023-12-20 17:23:31 -05:00
|
|
|
log.silly(JSON.stringify(getRouterParams(ev)), { label: "sigh" });
|
2023-10-03 00:56:16 -04:00
|
|
|
ev.context.chapterIndex = !!chapParam ? parseInt(chapParam) - 1 : 0;
|
|
|
|
});
|