Code

Updated check. Closes #15609
authorcajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 12 Feb 2010 13:50:48 +0000 (13:50 +0000)
committercajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 12 Feb 2010 13:50:48 +0000 (13:50 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@15618 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-plugins/fai/admin/fai/class_askClassName.inc

index 68a406dcd6433662a51da7d356f1258d6108b432..945c0d54f4a3dd7c23e43592494a3c756580b7c3 100644 (file)
@@ -137,7 +137,11 @@ class askClassName extends plugin
   {
     /* Call common method to give check the hook */
     $message= plugin::check();
-  
+
+    if($this->objectClass == "FAIscript" && preg_match("/^-/", $this->ClassName)) { 
+      $message[] = msgPool::invalid(_("Name"),preg_replace("/ /","_",$this->ClassName),"/[^_]/");
+    }   
+
     if($this->ClassName != preg_replace("/ /","",trim($this->ClassName))){
       $message[] = msgPool::invalid(_("Name"),preg_replace("/ /","_",$this->ClassName),"/[^_]/");
     }