Skip to content

Commit 9b7e897

Browse files
committed
fix: send hitokoto replies directly
1 parent 2d41f48 commit 9b7e897

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/modules/utils/index.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import type { PluginFunction } from '~/lib/plugin'
22

3-
import { escapeMarkdown } from '~/lib/helper'
43
import { setTGBotCommands } from '~/lib/register-command'
54

65
import { fetchHitokoto } from '../mx-space/api/hitokoto'
@@ -13,9 +12,10 @@ export const register: PluginFunction = async (ctx) => {
1312
group: '其他小功能',
1413
command: 'hitokoto',
1514
description: '获取一条一言',
16-
handler: async () => {
15+
handler: async (_, ctx) => {
1716
const { hitokoto } = await fetchHitokoto()
18-
return escapeMarkdown(hitokoto)
17+
await ctx.reply(hitokoto)
18+
return true
1919
},
2020
},
2121
])

0 commit comments

Comments
 (0)