Skip to content

Commit 1dfcc64

Browse files
JasonGrossZimmi48
authored andcommitted
Adjust formatting a bit
1 parent a7093ff commit 1dfcc64

File tree

1 file changed

+6
-11
lines changed

1 file changed

+6
-11
lines changed

src/helpers.ml

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -154,18 +154,13 @@ let download_cps ~uri ~with_file =
154154
| Some new_uri ->
155155
inner_download new_uri
156156
| None ->
157-
let msg =
158-
Printf.sprintf "Redirected from %s, but no Location header found"
159-
(Uri.to_string uri)
160-
in
161-
Lwt.return_error msg )
162-
| status_code ->
163-
let msg =
164-
Printf.sprintf "HTTP request to %s failed with status code: %s"
157+
f "Redirected from %s, but no Location header found"
165158
(Uri.to_string uri)
166-
(Code.string_of_status status_code)
167-
in
168-
Lwt.return_error msg
159+
|> Lwt.return_error )
160+
| status_code ->
161+
f "HTTP request to %s failed with status code: %s" (Uri.to_string uri)
162+
(Code.string_of_status status_code)
163+
|> Lwt.return_error
169164
in
170165
inner_download uri
171166

0 commit comments

Comments
 (0)