1
mirror of https://github.com/rclone/rclone synced 2024-12-29 22:26:24 +01:00
rclone/lib/rest
Eng Zer Jun c4bad5c1bc lib/rest: remove unnecessary nil check
From the Go docs:

  "A `nil` map is equivalent to an empty map. [1]

Therefore, an additional nil check for `opts.ExtraHeaders` before the loop is
unnecessary because `opts.ExtraHeaders` is a `map`.

[1]: https://go.dev/ref/spec#Map_types

Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2023-08-09 19:17:42 +09:00
..
headers_test.go backend/http: support content-range response header 2022-11-08 13:04:17 +00:00
headers.go backend/http: support content-range response header 2022-11-08 13:04:17 +00:00
rest.go lib/rest: remove unnecessary nil check 2023-08-09 19:17:42 +09:00
url_test.go build: more pre go1.8 workarounds removed 2019-05-08 15:14:51 +01:00
url.go Error strings should not be capitalized 2022-06-23 23:26:02 +02:00