mirror of
https://github.com/fumiama/NanoBot.git
synced 2026-06-09 20:50:23 +08:00
optimize(context): SendImage
This commit is contained in:
@@ -204,7 +204,9 @@ func (ctx *Ctx) SendImage(file string, replytosender bool, caption ...any) (repl
|
|||||||
Type: FileTypeImage,
|
Type: FileTypeImage,
|
||||||
URL: file,
|
URL: file,
|
||||||
}
|
}
|
||||||
_, _ = ctx.SendPlainMessage(replytosender, caption...)
|
if len(caption) > 0 {
|
||||||
|
_, _ = ctx.SendPlainMessage(replytosender, caption...)
|
||||||
|
}
|
||||||
if OnlyQQGroup(ctx) {
|
if OnlyQQGroup(ctx) {
|
||||||
reply, err = ctx.PostFileToQQGroup(ctx.Message.ChannelID, fp)
|
reply, err = ctx.PostFileToQQGroup(ctx.Message.ChannelID, fp)
|
||||||
} else if OnlyQQPrivate(ctx) {
|
} else if OnlyQQPrivate(ctx) {
|
||||||
|
|||||||
Reference in New Issue
Block a user