From 1fd0f95688fb4a8fb612d1164501030588f22a62 Mon Sep 17 00:00:00 2001 From: Claudio Sacerdoti Coen Date: Mon, 31 May 2004 10:56:06 +0000 Subject: [PATCH] theory:path/index.theory are not rewritten to theory:/path.theory if theory:path/index.theory exists in the database. --- helm/ocaml/getter/http_getter_map.ml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/helm/ocaml/getter/http_getter_map.ml b/helm/ocaml/getter/http_getter_map.ml index 1b5d209d3..e3a4ab2fc 100644 --- a/helm/ocaml/getter/http_getter_map.ml +++ b/helm/ocaml/getter/http_getter_map.ml @@ -46,7 +46,9 @@ class map dbname = theory:/path/t.theory into theory:/path/t/index.theory when cic:/path/t/ exists *) method private normalize_key key = - if Pcre.pmatch ~rex:index_RE key then + if Pcre.pmatch ~rex:index_RE key && + (try ignore (Dbm.find db key); false with Not_found -> true) + then (* we substitute /index.theory with .theory *) String.sub key 0 (String.length key - 13) ^ ".theory" else key -- 2.39.2