$return = $GLOBALS['translation_tables']['yoomedia']['error_codes'][$errorCode];
} else {
// Log missing entries
- debug_report_bug(sprintf("Unknown error code <strong>%s</strong> detected.", $errorCode));
+ debug_report_bug(sprintf("Unknown error code <strong>%s[%s]</strong> detected.", $errorCode, gettype($errorCode)));
}
// Return value
if (((time() - $time) >= ($reload * 60*60)) && ($time > 0)) {
// Remove entry
SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_yoomedia_reload` WHERE `id`=%s LIMIT 1",
- array($id), __FUNCTION__, __LINE__);
+ array($id), __FUNCTION__, __LINE__);
} else {
// Dont' sent again this mail
$reloaded = $time;
// Remove carrige-return
$code = str_replace("\n", '', $code);
+
} else {
// Should not happen!
debug_report_bug('Cannot parse response. Raw response:<pre>' . print_r($response, true) . '</pre>');
}
+ // Fix empty code to bad
+ if (empty($code)) {
+ $code = -999;
+ } // END - if
+
// Return error code
return $code;
}