]> wagnertech.de Git - mfinanz.git/blobdiff - bin/mozilla/ap.pl
Alle Vorkommen von all_departments abgesichert.
[mfinanz.git] / bin / mozilla / ap.pl
index 8f643e57ef2458bf3d499a02996113ff29cd1a1f..80680efc643a054544962479ed6dc428541f4c07 100644 (file)
@@ -170,14 +170,14 @@ sub create_links {
   }
 
   # departments
-  if (@{ $form->{all_departments} }) {
+  if (@{ $form->{all_departments} || [] }) {
     $form->{selectdepartment} = "<option>\n";
     $form->{department}       = "$form->{department}--$form->{department_id}";
 
     map {
       $form->{selectdepartment} .=
         "<option>$_->{description}--$_->{id}\n"
-    } (@{ $form->{all_departments} });
+    } (@{ $form->{all_departments} || [] });
   }
 
   $form->{employee} = "$form->{employee}--$form->{employee_id}";
@@ -1222,13 +1222,13 @@ sub search {
   }
 
   # departments
-  if (@{ $form->{all_departments} }) {
+  if (@{ $form->{all_departments} || [] }) {
     $form->{selectdepartment} = "<option>\n";
 
     map {
       $form->{selectdepartment} .=
         "<option>$_->{description}--$_->{id}\n"
-    } (@{ $form->{all_departments} });
+    } (@{ $form->{all_departments} || [] });
   }
 
   my $department = qq|