Revert one usecase

This commit is contained in:
LEGOlord208 2017-08-29 07:46:24 +02:00
parent fede59cfa0
commit 9a36098f5c
No known key found for this signature in database
GPG key ID: 3A818BC1F5617A24

View file

@ -1383,9 +1383,10 @@ func (s *Session) ChannelMessageSendComplex(channelID string, data *MessageSend)
for i, file := range files {
h := make(textproto.MIMEHeader)
h.Set("Content-Disposition",
`form-data; name="file`+strconv.Itoa(i)+
`"; filename="`+quoteEscaper.Replace(file.Name)+
`"`)
fmt.Sprintf(`form-data; name="file%d"; filename="%s"`,
i,
quoteEscaper.Replace(file.Name),
))
contentType := file.ContentType
if contentType == "" {
contentType = "application/octet-stream"