import { RouteHandler, RouteConfig } from "@hono/zod-openapi";
type AppRouteHandler<R extends RouteConfig> = RouteHandler<R, AppBindings>;
export const getChannelById: AppRouteHandler<GetChannelByIdRoute> = async (c) => {
const { channelId } = c.req.valid("param");
const channel = await ChannelService.getChannelDetails(channelId);
return c.json(channel, 200);
};
import { RouteHandler, RouteConfig } from "@hono/zod-openapi";
type AppRouteHandler<R extends RouteConfig> = RouteHandler<R, AppBindings>;
export const getChannelById: AppRouteHandler<GetChannelByIdRoute> = async (c) => {
const { channelId } = c.req.valid("param");
const channel = await ChannelService.getChannelDetails(channelId);
return c.json(channel, 200);
};