Skip to content
Snippets Groups Projects
Commit e5f9f7e1 authored by Robert Ricci's avatar Robert Ricci
Browse files

Don't require wiki-only users to fill out all fields.

parent b46c5262
No related branches found
Tags noelvin
No related merge requests found
...@@ -132,17 +132,10 @@ else { ...@@ -132,17 +132,10 @@ else {
# #
# These are the fields that we allow to come in from the XMLfile. # These are the fields that we allow to come in from the XMLfile.
# This first set is required by all types of users
# #
my %required = ("name" => "usr_name", my %required = ("name" => "usr_name",
"email" => "usr_email", "email" => "usr_email",
"address" => "usr_addr",
"city" => "usr_city",
"state" => "usr_state",
"zip" => "usr_zip",
"country" => "usr_country",
"phone" => "usr_phone",
"title" => "usr_title",
"affiliation" => "usr_affil",
"password" => undef); "password" => undef);
my %optional = ("login" => "uid", my %optional = ("login" => "uid",
...@@ -151,6 +144,23 @@ my %optional = ("login" => "uid", ...@@ -151,6 +144,23 @@ my %optional = ("login" => "uid",
"shell" => "usr_shell", "shell" => "usr_shell",
"pubkey" => undef); "pubkey" => undef);
#
# These are required for most users, but are optional for wiki-only users
#
my %usually_required = ("address" => "usr_addr",
"city" => "usr_city",
"state" => "usr_state",
"zip" => "usr_zip",
"country" => "usr_country",
"phone" => "usr_phone",
"title" => "usr_title",
"affiliation" => "usr_affil");
if ($type eq "wikionly") {
%optional = (%optional, %usually_required);
} else {
%required = (%required, %usually_required);
}
($WIKISUPPORT ? \%required : \%optional)->{"wikiname"} = "wikiname"; ($WIKISUPPORT ? \%required : \%optional)->{"wikiname"} = "wikiname";
# #
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment