Commit f8f427c
committed
ignition: Use http.ServeContent
This does not matter much in the context of ignition, but `http.ServeContent`
is more featureful than using `io.Copy`:
https://pkg.go.dev/net/http#ServeContent
> The main benefit of ServeContent over io.Copy is that it handles Range
> requests properly, sets the MIME type, and handles If-Match,
> If-Unmodified-Since, If-None-Match, If-Modified-Since, and If-Range requests.
Signed-off-by: Christophe Fergeau <[email protected]>1 parent 7ce69df commit f8f427c
1 file changed
+3
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
296 | 296 | | |
297 | 297 | | |
298 | 298 | | |
299 | | - | |
| 299 | + | |
300 | 300 | | |
301 | | - | |
302 | | - | |
303 | | - | |
304 | | - | |
305 | | - | |
| 301 | + | |
| 302 | + | |
306 | 303 | | |
307 | 304 | | |
308 | 305 | | |
| |||
0 commit comments