let errno dbtype dbd =
wrap
- (fun d -> match List.assoc dbtype d with
- | Mysql dbd -> mysql_err (HMysql.errno dbd)
- | Sqlite dbd -> sqlite_err (HSqlite3.errno dbd)
- | FakeMySql -> assert false)
+ (fun d ->
+ try
+ match List.assoc dbtype d with
+ | Mysql dbd -> mysql_err (HMysql.errno dbd)
+ | Sqlite dbd -> sqlite_err (HSqlite3.errno dbd)
+ | FakeMySql -> assert false
+ with Not_found -> OK)
dbd
;;
let isMysql dbtype dbd =
wrap
- (fun d -> match List.assoc dbtype d with Mysql _ -> true | _ -> false)
+ (fun d ->
+ try
+ match List.assoc dbtype d with Mysql _ -> true | _ -> false
+ with Not_found -> false)
dbd
;;