From 47c742d53bc24da0815fd62313005557c1cab8f6 Mon Sep 17 00:00:00 2001 From: ยท๐‘‘๐‘ด๐‘•๐‘‘๐‘ฉ๐‘ค Date: Thu, 11 Dec 2025 20:25:21 +0000 Subject: use Hashtbl.find_opt --- lib/input.ml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/input.ml b/lib/input.ml index 208cf4d..957e7fd 100644 --- a/lib/input.ml +++ b/lib/input.ml @@ -292,7 +292,9 @@ let jg_models2 (input : t) (needle : string) : Jingoo.Jg_types.tvalue = htbl end in - try Hashtbl.find hashtbl needle with Not_found -> Tnull + match Hashtbl.find_opt hashtbl needle with + | Some value -> value + | None -> Tnull (* NIXPKGS ********************************************************************) -- cgit v1.2.3