fix(route/follow): add feed image and fix radar rules (#16699)

* feat: add feed image

* fix: fix radar rule
This commit is contained in:
karasu 2024-09-11 19:39:12 +08:00 committed by GitHub
parent f622262985
commit 930682221f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 2 deletions

View File

@ -1,5 +1,5 @@
import type { Data, Route } from '@/types';
import { Context } from 'hono';
import type { Context } from 'hono';
import ofetch from '@/utils/ofetch';
import type { FollowResponse, Profile, Subscription } from './types';
@ -10,7 +10,7 @@ export const route: Route = {
radar: [
{
source: ['app.follow.is/profile/:uid'],
target: '/follow/profile/:uid',
target: '/profile/:uid',
},
],
handler,
@ -34,5 +34,6 @@ async function handler(ctx: Context): Promise<Data> {
link: `https://app.follow.is/feed/${subscription.feedId}`,
})),
link: `https://app.follow.is/profile/${uid}`,
image: profile.data.image,
};
}