mirror of
https://github.com/imsyy/DailyHotApi.git
synced 2026-01-12 21:24:55 +08:00
14 lines
275 B
TypeScript
14 lines
275 B
TypeScript
import type { Handler } from "hono";
|
|
import { config } from "./config.js";
|
|
|
|
const handler: Handler = (c) => {
|
|
if (config.DISALLOW_ROBOT) {
|
|
return c.text("User-agent: *\nDisallow: /");
|
|
} else {
|
|
c.status(404);
|
|
return c.text("");
|
|
}
|
|
};
|
|
|
|
export default handler;
|