From f22eaa92bcdb51f833640be5dc770dfce1dda868 Mon Sep 17 00:00:00 2001 From: hickert Date: Fri, 24 Oct 2008 14:54:17 +0000 Subject: [PATCH] Updated macro checks git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@12774 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/gofon/macro/class_gofonMacro.inc | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/plugins/gofon/macro/class_gofonMacro.inc b/plugins/gofon/macro/class_gofonMacro.inc index 6c273b53e..6043a63f6 100644 --- a/plugins/gofon/macro/class_gofonMacro.inc +++ b/plugins/gofon/macro/class_gofonMacro.inc @@ -286,12 +286,22 @@ class macro extends plugin # if(substr_count($s_linestr,",") !=2){ # return(sprintf(_("More than two ',' given in line : '%s'. Remember that parameters are seperated by '|'."),$i_linenum)); # } - /* Multiple () are not supproted currently ... */ - if(substr_count($s_linestr,"(") >1 ){ - return(sprintf(_("More than one '(' is currently not supported. Line : '%s'."),$i_linenum)); + +# /* Multiple () are not supproted currently ... */ +# if(substr_count($s_linestr,"(") >1 ){ +# return(sprintf(_("More than one '(' is currently not supported. Line : '%s'."),$i_linenum)); +# } +# if(substr_count($s_linestr,")") >1 ){ +# return(sprintf(_("More than one ')' is currently not supported. Line : '%s'."),$i_linenum)); +# } + + /* Check if there is an application given */ + if(empty($tmp[1])){ + return(sprintf(_("There is no application given in line : '%s'."),$i_linenum)); } - if(substr_count($s_linestr,")") >1 ){ - return(sprintf(_("More than one ')' is currently not supported. Line : '%s'."),$i_linenum)); + /* Check if there is an extension given */ + if(empty($tmp[0])){ + return(sprintf(_("There is no extension type given in line : '%s'."),$i_linenum)); } /* Create extension entry for current line -- 2.30.2