git.annexia.org
/
cocanwiki.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Commented a bug.
[cocanwiki.git]
/
scripts
/
create_user.ml
diff --git
a/scripts/create_user.ml
b/scripts/create_user.ml
index
2767434
..
b8b8e6c
100644
(file)
--- a/
scripts/create_user.ml
+++ b/
scripts/create_user.ml
@@
-1,7
+1,7
@@
(* COCANWIKI - a wiki written in Objective CAML.
* Written by Richard W.M. Jones <rich@merjis.com>.
* Copyright (C) 2004 Merjis Ltd.
(* COCANWIKI - a wiki written in Objective CAML.
* Written by Richard W.M. Jones <rich@merjis.com>.
* Copyright (C) 2004 Merjis Ltd.
- * $Id: create_user.ml,v 1.
4 2004/10/11 14:13:04
rich Exp $
+ * $Id: create_user.ml,v 1.
5 2004/10/23 09:36:11
rich Exp $
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@
-52,9
+52,6
@@
let run r (q : cgi) (dbh : Dbi.connection) hostid _ _ =
if String.length username > 32 || String.length password > 32 then
*)
if String.length username > 32 || String.length password > 32 then
*)
- let email = trim (q#param "email") in
- let email = if string_is_whitespace email then `Null else `String email in
-
(* Not a duplicate? *)
let sth = dbh#prepare_cached "select id from users
where hostid = ? and name = ?" in
(* Not a duplicate? *)
let sth = dbh#prepare_cached "select id from users
where hostid = ? and name = ?" in
@@
-77,13
+74,13
@@
let run r (q : cgi) (dbh : Dbi.connection) hostid _ _ =
let force_password_change = q#param_true "force_password_change" in
(* Create the user account. *)
let force_password_change = q#param_true "force_password_change" in
(* Create the user account. *)
- let sth = dbh#prepare_cached "insert into users (name, password,
email,
+ let sth = dbh#prepare_cached "insert into users (name, password,
hostid, can_edit, can_manage_users,
can_manage_contacts, can_manage_site,
can_edit_global_css, can_import_mail,
force_password_change)
hostid, can_edit, can_manage_users,
can_manage_contacts, can_manage_site,
can_edit_global_css, can_import_mail,
force_password_change)
- values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?
, ?
)" in
- sth#execute [`String username; `String password;
email;
`Int hostid;
+ values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)" in
+ sth#execute [`String username; `String password; `Int hostid;
`Bool can_edit; `Bool can_manage_users;
`Bool can_manage_contacts; `Bool can_manage_site;
`Bool can_edit_global_css; `Bool can_import_mail;
`Bool can_edit; `Bool can_manage_users;
`Bool can_manage_contacts; `Bool can_manage_site;
`Bool can_edit_global_css; `Bool can_import_mail;