Code

Simplify array use
authorcajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 30 Jan 2008 14:39:14 +0000 (14:39 +0000)
committercajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 30 Jan 2008 14:39:14 +0000 (14:39 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8671 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-si/modules/ServerPackages.pm

index c4de90d9a7ab48b691c1fdb41c6e3929cd4dce69..c06aba4f0ab7895ddaa805c312e4ed16da0fc80a 100644 (file)
@@ -744,8 +744,7 @@ sub new_ldap_config {
     my $base;
 
     # Do we need to look at an object class?
-    my $cnt= @servers;
-    if ($cnt < 1){
+    if (length(@servers) < 1){
            $mesg = $ldap->search( base   => $ldap_base,
                            scope  => 'sub',
                            attrs => ['dn', 'gotoLdapServer'],