Skip to content

Commit

Permalink
beta318 (#318)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hoshinonyaruko authored Feb 6, 2024
1 parent c93cce8 commit 48779fc
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions handlers/message_parser.go
Original file line number Diff line number Diff line change
Expand Up @@ -240,13 +240,13 @@ func parseMessageContent(paramsMessage callapi.ParamsContent, message callapi.Ac
} else {
localRecordPattern = regexp.MustCompile(`\[CQ:record,file=file://([^\]]+?)\]`)
}
httpUrlImagePattern := regexp.MustCompile(`\[CQ:image,file=http://(.+)\]`)
httpsUrlImagePattern := regexp.MustCompile(`\[CQ:image,file=https://(.+)\]`)
base64ImagePattern := regexp.MustCompile(`\[CQ:image,file=base64://(.+)\]`)
base64RecordPattern := regexp.MustCompile(`\[CQ:record,file=base64://(.+)\]`)
httpUrlRecordPattern := regexp.MustCompile(`\[CQ:record,file=http://(.+)\]`)
httpsUrlRecordPattern := regexp.MustCompile(`\[CQ:record,file=https://(.+)\]`)
mdPattern := regexp.MustCompile(`\[CQ:markdown,data=base64://(.+)\]`)
httpUrlImagePattern := regexp.MustCompile(`\[CQ:image,file=http://(.+?)\]`)
httpsUrlImagePattern := regexp.MustCompile(`\[CQ:image,file=https://(.+?)\]`)
base64ImagePattern := regexp.MustCompile(`\[CQ:image,file=base64://(.+?)\]`)
base64RecordPattern := regexp.MustCompile(`\[CQ:record,file=base64://(.+?)\]`)
httpUrlRecordPattern := regexp.MustCompile(`\[CQ:record,file=http://(.+?)\]`)
httpsUrlRecordPattern := regexp.MustCompile(`\[CQ:record,file=https://(.+?)\]`)
mdPattern := regexp.MustCompile(`\[CQ:markdown,data=base64://(.+?)\]`)

patterns := []struct {
key string
Expand Down

0 comments on commit 48779fc

Please sign in to comment.