Code

* bugfix in function send_usr_msg * function accepts gosa messages without a group...
authorrettenbe <rettenbe@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 3 Jul 2008 16:44:56 +0000 (16:44 +0000)
committerrettenbe <rettenbe@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 3 Jul 2008 16:44:56 +0000 (16:44 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11531 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-si/server/events/gosaTriggered.pm

index efeb3f51d9de3d633c9beef9157f35af772383e9..cf73dd0227faf6f6c8b0b351a64cfea1cedfd8a5 100644 (file)
@@ -72,8 +72,8 @@ sub send_user_msg {
     #my $subject = &decode_base64(@{$msg_hash->{'subject'}}[0]);
     my $subject = @{$msg_hash->{'subject'}}[0];
     my $from = @{$msg_hash->{'from'}}[0];
-    my @users = @{$msg_hash->{'users'}};
-       my @groups = @{$msg_hash->{'groups'}};
+    my @users = exists $msg_hash->{'users'} ? @{$msg_hash->{'users'}} : () ;
+       my @groups = exists $msg_hash->{'groups'} ? @{$msg_hash->{'groups'}} : ();
     my $delivery_time = @{$msg_hash->{'delivery_time'}}[0];
     #my $message = &decode_base64(@{$msg_hash->{'message'}}[0]);
     my $message = @{$msg_hash->{'message'}}[0];