reddit: unexpected status error codes are bubbled up
All checks were successful
/ push (push) Successful in 2m19s
All checks were successful
/ push (push) Successful in 2m19s
This commit is contained in:
parent
ca96d4a805
commit
c50b4a18a1
|
@ -82,7 +82,7 @@ func (reddit *Reddit) downloadImage(ctx context.Context, post Post, kind bmessag
|
||||||
return nil, errs.Fail("unexpected status code when trying to download images",
|
return nil, errs.Fail("unexpected status code when trying to download images",
|
||||||
"url", url,
|
"url", url,
|
||||||
"status_code", resp.StatusCode,
|
"status_code", resp.StatusCode,
|
||||||
)
|
).Code(resp.StatusCode)
|
||||||
}
|
}
|
||||||
idleSpeedStr := reddit.Config.String("download.timeout.idlespeed")
|
idleSpeedStr := reddit.Config.String("download.timeout.idlespeed")
|
||||||
metricSpeed, _ := units.ParseMetricBytes(idleSpeedStr)
|
metricSpeed, _ := units.ParseMetricBytes(idleSpeedStr)
|
||||||
|
|
Loading…
Reference in a new issue