]> wagnertech.de Git - mfinanz.git/blobdiff - bin/mozilla/admin.pl
css und images
[mfinanz.git] / bin / mozilla / admin.pl
index 75fb790aa57c7fc3a9988626afaf332b5bcd4e05..ff4641adbe67598f82559c56981f5efd44fb6862 100755 (executable)
@@ -476,7 +476,7 @@ sub save_user {
   $user->{templates} =~ s|.*/||;
   $user->{templates} =  $::lx_office_conf{paths}->{templates} . "/$user->{templates}";
 
-  my $myconfig = new User(id => $form->{id});
+  my $myconfig = new User(id => $user->{id});
 
   $::form->show_generic_error($::locale->text('Dataset missing!'))       unless $user->{dbname};
   $::form->show_generic_error($::locale->text('Database User missing!')) unless $user->{dbuser};
@@ -542,7 +542,7 @@ sub save_user {
   # Add new user to his groups.
   if (ref $form->{new_user_group_ids} eq 'ARRAY') {
     my $all_groups = $main::auth->read_groups();
-    my %user       = $main::auth->read_user(login => $user->{login});
+    my %user       = $main::auth->read_user(login => $myconfig->{login});
 
     foreach my $group_id (@{ $form->{new_user_group_ids} }) {
       my $group = $all_groups->{$group_id};
@@ -564,7 +564,7 @@ sub save_user {
       $form->error($::locale->text('The settings were saved, but the password was not changed.') . ' ' . join(' ', $verifier->errors($result)));
     }
 
-    $main::auth->change_password($user->{login}, $::form->{new_password});
+    $main::auth->change_password($myconfig->{login}, $::form->{new_password});
   }
 
   $::form->redirect($::locale->text('User saved!'));