From f76d4b46a6e19d59adb1c6e7c60b324380380a8e Mon Sep 17 00:00:00 2001 From: Mylloon Date: Sat, 13 May 2023 17:21:05 +0200 Subject: [PATCH] better err msg --- lib/net.ml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/net.ml b/lib/net.ml index 0409003..7694378 100644 --- a/lib/net.ml +++ b/lib/net.ml @@ -40,7 +40,7 @@ let get_session () = | [] -> failwith "Session ID not found" in find_session_id (Yojson.Safe.Util.to_assoc value) - | _ -> failwith "Invalid JSON" + | _ -> failwith "get_session | Invalid JSON" ;; let close_session id = execute_delete_request (driver id) = "{\"value\":null}" @@ -61,8 +61,8 @@ let rec wait_for_load session_id = then ( Unix.sleep 1; wait_for_load session_id) - | _ -> failwith "Error when waiting for load") - | _ -> failwith "Invalid JSON" + | _ -> failwith "Error when waiting for page to load") + | _ -> failwith "wait_for_load | Invalid JSON" ;; let navigate ?(wait = true) url session_id =