1
0
mirror of https://github.com/fumiama/NanoBot.git synced 2026-06-06 03:00:24 +08:00

fix multipart

This commit is contained in:
源文雨
2023-10-16 11:47:22 +09:00
parent 8bae3c1ad2
commit 731f8ab89e

View File

@@ -3,6 +3,7 @@ package nano
import (
"encoding/json"
"reflect"
"strings"
"time"
"github.com/pkg/errors"
@@ -148,7 +149,7 @@ func (bot *Bot) postMessageTo(ep string, content *MessagePost) (*Message, error)
if xi.IsZero() {
continue
}
tag := t.Field(i).Tag.Get("json")
tag, _, _ := strings.Cut(t.Field(i).Tag.Get("json"), ",")
if tag == "-" {
tag = "file_image"
}