From dd085029551066d2d91475d13e5b6e1546be5d66 Mon Sep 17 00:00:00 2001 From: DIYgod Date: Fri, 20 Dec 2024 22:50:49 +0800 Subject: [PATCH] feat: add follow limit config --- lib/api/follow/config.ts | 1 + lib/config.ts | 2 ++ 2 files changed, 3 insertions(+) diff --git a/lib/api/follow/config.ts b/lib/api/follow/config.ts index 1eef74e5ab2e73..e8275f83a5d7bc 100644 --- a/lib/api/follow/config.ts +++ b/lib/api/follow/config.ts @@ -17,6 +17,7 @@ const handler: RouteHandler = (ctx) => ownerUserId: config.follow.ownerUserId, description: config.follow.description, price: config.follow.price, + limit: config.follow.limit, }); export { route, handler }; diff --git a/lib/config.ts b/lib/config.ts index 2b8a687e2b6183..c50fa679f3327a 100644 --- a/lib/config.ts +++ b/lib/config.ts @@ -90,6 +90,7 @@ export type Config = { ownerUserId?: string; description?: string; price?: number; + limit?: number; }; // Route-specific Configurations @@ -519,6 +520,7 @@ const calculateValue = () => { ownerUserId: envs.FOLLOW_OWNER_USER_ID, description: envs.FOLLOW_DESCRIPTION, price: toInt(envs.FOLLOW_PRICE), + limit: toInt(envs.FOLLOW_LIMIT), }, // Route-specific Configurations