Skip to content
Permalink
Browse files

Check for additional bad user profile field names. bug #10941

  • Loading branch information...
perlDreamer committed Sep 9, 2009
1 parent bd02a8c commit e1c5d4aa47c5e1f657317949729e49b1b64e1c16
Showing with 7 additions and 4 deletions.
  1. +1 −0 docs/changelog/7.x.x.txt
  2. +1 −1 lib/WebGUI/ProfileField.pm
  3. +5 −3 t/ProfileField.t
@@ -27,6 +27,7 @@
- fixed #10889: Old Matrixs break for Admin users
- fixed #10939: Commit with Approval workflow does not show confirmation screen
- fixed #10943: ThingyRecord JS Broken
- fixed #10941: New user profile fields with unfortunate names

7.7.19
- fixed #10838: Forwarded forum post email to new CS adds reply to original thread
@@ -67,7 +67,7 @@ Return true iff fieldName is reserved and therefore not usable as a profile fiel
sub isReservedFieldName {
my $class = shift;
my $fieldName = shift;
return isIn($fieldName, qw/userId func op wg_privacySettings/);
return isIn($fieldName, qw/userId shop specialState func op wg_privacySettings username authMethod dateCreated lastUpdated karma status referringAffiliate friendsGroup/);
}

#-------------------------------------------------------------------
@@ -33,7 +33,7 @@ WebGUI::Test->usersToDelete($newUser);
#----------------------------------------------------------------------------
# Tests

plan tests => 45; # Increment this number for each test you create
plan tests => 47; # Increment this number for each test you create

#----------------------------------------------------------------------------
# Test the creation of ProfileField
@@ -135,8 +135,10 @@ ok( WebGUI::ProfileField->isReservedFieldName('op'), '... op');
ok( WebGUI::ProfileField->isReservedFieldName('userId'), '... userId');
ok( WebGUI::ProfileField->isReservedFieldName('wg_privacySettings'), '... wg_privacySettings');
ok( !WebGUI::ProfileField->isReservedFieldName('function'), '... function is not');
ok( !WebGUI::ProfileField->isReservedFieldName('operation'), '... operation is no');
ok( !WebGUI::ProfileField->isReservedFieldName('shop'), '... shop is not');
ok( !WebGUI::ProfileField->isReservedFieldName('operation'), '... operation is not');
ok( WebGUI::ProfileField->isReservedFieldName('shop'), '... shop is not');
ok( WebGUI::ProfileField->isReservedFieldName('username'), '... username');
ok( WebGUI::ProfileField->isReservedFieldName('status'), '... status');

###########################################################
#

0 comments on commit e1c5d4a

Please sign in to comment.
You can’t perform that action at this time.