BUG 8665 Extra: Changing log messages.

This commit is contained in:
ralpheav
2013-05-08 10:57:35 -04:00
parent 2bae6d540b
commit c7ef775bdd
3 changed files with 12 additions and 13 deletions

View File

@@ -501,7 +501,7 @@ class workspaceTools
$filesDir = $doclevel[$length - 1];
if (is_dir(PATH_DOCUMENT) && is_writable($filesDir)) {
CLI::logging("Error:" . PATH_DOCUMENT . " is not writable... please check the su permissions.\n");
CLI::logging(CLI::error("Error:" . PATH_DOCUMENT . " is not writable... please check the su permissions.\n"));
return;
}
@@ -511,7 +511,7 @@ class workspaceTools
$dirslength = sizeof($directory);
if (! @chdir(PATH_DOCUMENT)) {
CLI::logging("Cannot use Document directory. The upgrade must be done as root.\n");
CLI::logging(CLI::error("Cannot use Document directory. The upgrade must be done as root.\n"));
return;
}
@@ -535,7 +535,7 @@ class workspaceTools
G::rm_dir($UIdDir);
rmdir($UIdDir);//remove the diretory itself, G::rm_dir cannot do it
} else {
CLI::logging("Error: Failure at coping from $UIdDir...\n");
CLI::logging(CLI::error("Error: Failure at coping from $UIdDir...\n"));
}
} else {
CLI::logging("$UIdDir is empty, removing it\n");
@@ -562,7 +562,7 @@ class workspaceTools
if (copy($black . $goalFile, $black . $newpattern[0] . '/' . $newpattern[1])) {
unlink($file[$index]);
} else {
CLI::logging("Error: Failure at copy $file[$index] files...\n");
CLI::logging(CLI::error("Error: Failure at copy $file[$index] files...\n"));
}
}
}
@@ -573,9 +573,9 @@ class workspaceTools
$conf = new Configurations();
if ($conf->exists("ENVIRONMENT_SETTINGS")) {
$conf->setDirectoryStructureVer(2);
CLI::logging("Please notice Version Directory Structure is 2 now.\n");
CLI::logging(CLI::info("Version Directory Structure is 2 now.\n"));
} else {
CLI::logging("Error: Issue found at try to use ENVIRONMENT_SETTINGS row.\n");
CLI::logging(CLI::error("Error: found at try to use ENVIRONMENT_SETTINGS row.\n"));
return;
}
}

View File

@@ -177,10 +177,10 @@ class Translation extends BaseTranslation
//$json = new Services_JSON(); DEPRECATED
$f = fopen( $cacheFileJS, 'w' );
if ($f==false) {
echo "Error: Cannot write into cachefilejs: $cacheFileJS\n";
if ($f == false) {
error_log("Error: Cannot write into cachefilejs: $cacheFileJS\n");
} else {
fwrite( $f, "var G_STRINGS =" . Bootstrap::json_encode( $translationJS ) . ";\n" );
fwrite( $f, "var G_STRINGS =" . Bootstrap::json_encode( $translationJS ) . ";\n");
fclose( $f );
}
@@ -413,7 +413,6 @@ class Translation extends BaseTranslation
if (! file_exists( $filePath )) {
//the transaltions table file doesn't exist, then build it
if (! is_dir( dirname( $this->envFilePath ) )) {
G::mk_dir( dirname( $this->envFilePath ) );
}
@@ -422,7 +421,7 @@ class Translation extends BaseTranslation
$params = self::getInfoFromPOFile( $basePOFile );
$this->addTranslationEnvironment( $params['LOCALE'], $params['HEADERS'], $params['COUNT'] );
//getting more lanuguage translations
//getting more language translations
$files = glob( $translationsPath . "*.po" );
foreach ($files as $file) {
$params = self::getInfoFromPOFile( $file );

View File

@@ -71,7 +71,7 @@ if (file_exists( $realPath )) {
}
if (! $sw_file_exists) {
$error_message = "'" .$realPath." " .$realPath1." ". $oAppDocument->Fields['APP_DOC_FILENAME'] . "' " . G::LoadTranslation( 'ID_ERROR_STREAMING_FILE' );
$error_message = G::LoadTranslation( 'ID_ERROR_STREAMING_FILE' );
if ((isset( $_POST['request'] )) && ($_POST['request'] == true)) {
$res['success'] = 'failure';
$res['message'] = $error_message;