aboutsummaryrefslogtreecommitdiff
path: root/lib/http.ml
diff options
context:
space:
mode:
authorAdelyn Breedlove <[email protected]>2019-01-28 07:41:20 -0700
committerAdelyn Breedlove <[email protected]>2019-01-28 07:41:20 -0700
commite48af10e04a4aea4eb72dac58b83fc7cc080e1bd (patch)
tree78a0cf1f78855982ea54c78ac36f7fd89c5a1122 /lib/http.ml
parentSwitch to ID abstractions internally (diff)
downloaddisml-e48af10e04a4aea4eb72dac58b83fc7cc080e1bd.tar.xz
disml-e48af10e04a4aea4eb72dac58b83fc7cc080e1bd.zip
Fix Message.t.mentions
Diffstat (limited to 'lib/http.ml')
-rw-r--r--lib/http.ml3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/http.ml b/lib/http.ml
index 9799d7a..8927f47 100644
--- a/lib/http.ml
+++ b/lib/http.ml
@@ -4,7 +4,6 @@ open Cohttp
module Base = struct
exception Invalid_Method
- exception Bad_response_headers
let rl = ref Rl.empty
@@ -30,7 +29,7 @@ module Base = struct
(match Response.headers resp
|> Rl.rl_of_header with
| Some r -> Mvar.put (Rl.find_exn !rl path) r
- | None -> raise Bad_response_headers)
+ | None -> return ())
>>= fun () ->
match resp |> Response.status |> Code.code_of_status with
| 200 -> body |> Cohttp_async.Body.to_string >>| Yojson.Safe.from_string >>= Deferred.Or_error.return