remove /add_plant, add /plants, a board to replace it
This commit is contained in:
parent
8e44a11067
commit
bd99462e0a
13 changed files with 168 additions and 158 deletions
|
|
@ -149,14 +149,13 @@ let public_profile request =
|
|||
| Ok user -> (
|
||||
match user with
|
||||
| Some (nick, password, email, (bio, _)) ->
|
||||
let plants = Plant.view_user_plant_list nick in
|
||||
let user_info =
|
||||
Format.sprintf
|
||||
{|nick = `%s`; password = `%s`; email = `%s`; bio = '%s';
|
||||
<img src="/user/%s/avatar" class="img-thumbnail" alt="Your avatar picture">|}
|
||||
nick password email (Dream.html_escape bio) nick
|
||||
in
|
||||
user_info ^ plants
|
||||
user_info
|
||||
| None -> "incoherent db answer" )
|
||||
| Error e -> Format.sprintf "db error: %s" (Caqti_error.show e)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue