fmt
This commit is contained in:
parent
2003c52005
commit
95ebc4f9cf
2 changed files with 8 additions and 8 deletions
|
|
@ -14,7 +14,7 @@ let db_uri = Format.sprintf "sqlite3://%s" db
|
|||
let random_state = Random.State.make_self_init ()
|
||||
|
||||
module Db =
|
||||
(val Caqti_blocking.connect (Uri.of_string db_uri) |> Caqti_blocking.or_fail)
|
||||
(val Caqti_blocking.connect (Uri.of_string db_uri) |> Caqti_blocking.or_fail)
|
||||
|
||||
let () =
|
||||
let set_foreign_keys_on =
|
||||
|
|
|
|||
|
|
@ -345,14 +345,14 @@ let babillard_post request =
|
|||
; ("thread-comment", [ (_, comment) ])
|
||||
]
|
||||
| `Ok
|
||||
(("alt", [ (_, alt) ])
|
||||
( ("alt", [ (_, alt) ])
|
||||
:: ("file", file)
|
||||
:: ("lat-input", [ (_, lat) ])
|
||||
:: ("lng-input", [ (_, lng) ])
|
||||
:: ("subject", [ (_, subject) ])
|
||||
:: ("tags", [ (_, tags) ])
|
||||
:: ("thread-comment", [ (_, comment) ])
|
||||
:: ([] as categories) ) -> (
|
||||
:: ("lat-input", [ (_, lat) ])
|
||||
:: ("lng-input", [ (_, lng) ])
|
||||
:: ("subject", [ (_, subject) ])
|
||||
:: ("tags", [ (_, tags) ])
|
||||
:: ("thread-comment", [ (_, comment) ])
|
||||
:: ([] as categories) ) -> (
|
||||
let categories = List.map snd categories in
|
||||
match (Float.of_string_opt lat, Float.of_string_opt lng) with
|
||||
| None, _ -> render_unsafe "Invalide coordinate" request
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue