mirror of
https://mau.dev/mautrix/go.git
synced 2026-03-14 14:25:53 +01:00
client: log content length when uploading to external url
This commit is contained in:
parent
ed9820356e
commit
ed6dbcaaee
1 changed files with 4 additions and 1 deletions
|
|
@ -2041,7 +2041,10 @@ type ReqUploadMedia struct {
|
|||
}
|
||||
|
||||
func (cli *Client) tryUploadMediaToURL(ctx context.Context, url, contentType string, content io.Reader, contentLength int64) (*http.Response, error) {
|
||||
cli.Log.Debug().Str("url", url).Msg("Uploading media to external URL")
|
||||
cli.Log.Debug().
|
||||
Str("url", url).
|
||||
Int64("content_length", contentLength).
|
||||
Msg("Uploading media to external URL")
|
||||
req, err := http.NewRequestWithContext(ctx, http.MethodPut, url, content)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue