summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 0dccddd)
raw | patch | inline | side by side (parent: 0dccddd)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 6 Apr 2010 08:32:21 +0000 (08:32 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 6 Apr 2010 08:32:21 +0000 (08:32 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.6@17478 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-plugins/gofon/gofon/macro/class_gofonMacro.inc | patch | blob | history |
diff --git a/gosa-plugins/gofon/gofon/macro/class_gofonMacro.inc b/gosa-plugins/gofon/gofon/macro/class_gofonMacro.inc
index 817b7aeadb9b554e10e286768bcc5981fd51fd8a..64c36bf49c85f350e15071876e4dea6deed751bd 100644 (file)
@DEBUG (DEBUG_MYSQL, __LINE__, __FUNCTION__, __FILE__,$query, "Database query");
if(!$res){
new log("debug","gofonmacro/".get_class($this),"",array(),@mysql_error($r_current));
- return ( msgPool::dbquery("GOfon",@mysql_error($r_current),$Server['SERVER']));
+ @DEBUG (DEBUG_MYSQL, __LINE__, __FUNCTION__, __FILE__,"<b>".$query."</b>", "ERROR");
+ trigger_error(mysql_error($r_current));
+ return(
+ sprintf(
+ _("Macro could not be removed from server '%s', please check database consistency!"),
+ $Server['SERVER']));
}
@mysql_close($r_current);
}
*/
$tmp = explode(",", $s_linestr,3);
+ // No priority given ... somehow
+ if(count($tmp) == 2){
+ $tmp = array($tmp[0],"1",$tmp[1]);
+ }
+
/* Check if there is an application given */
- if(empty($tmp[1])){
+ if($tmp[2] == ""){
return(sprintf(_("Application missing in line %s!"),$i_linenum));
}
+ if($tmp[1] == ""){
+ return(sprintf(_("Priority missing in line %s!"),$i_linenum));
+ }
/* Check if there is an extension given */
- if(empty($tmp[0])){
+ if($tmp[0] == ""){
return(sprintf(_("Extension missing in line %s!"),$i_linenum));
}
@DEBUG (DEBUG_MYSQL, __LINE__, __FUNCTION__, __FILE__,$query, "Database query");
if(!$res){
new log("debug","gofonmacro/".get_class($this),"",array(),@mysql_error($r_con));
+ @DEBUG (DEBUG_MYSQL, __LINE__, __FUNCTION__, __FILE__,"<b>".$query."</b>", "ERROR");
+ trigger_error(mysql_error($r_con));
+ return(
+ sprintf(
+ _("Macro could not be added to server '%s', please check database consistency!"),
+ $cfg['SERVER']));
}
@mysql_close($r_con);
}