PHP-CS-Fixer

This commit is contained in:
Michael RICOIS 2016-11-29 17:09:24 +01:00
parent b646aa87d3
commit 5fd1d8bc04

View File

@ -90,7 +90,6 @@ if (file_exists('insee.lock')) {
}
if ($opts->cron || $oneShot) {
$execRef = new Scores_Exec_Ref('INSEE');
$execId = $execRef->start();
@ -148,7 +147,7 @@ if ($opts->cron || $oneShot) {
if ($integrity == 0 && file_exists($storageDir.'/'.$file)) {
$type = 'insee';
$ftpSize = filesize($storageDir.'/'.$file);
$ftpDate = date ("YmdHis", filemtime($storageDir.'/'.$file));
$ftpDate = date("YmdHis", filemtime($storageDir.'/'.$file));
echo date('Y-m-d H:i:s') . " - Ecriture du fichier $storageDir/$file\n";
// --- Enregistrement dans la base de données
@ -163,16 +162,13 @@ if ($opts->cron || $oneShot) {
if ($fileStmt->rowCount() == 0) {
try {
$conn->insert('sdv1.flux_insee', $data);
}
catch(\Doctrine\DBAL\DBALException $e) {
} catch (\Doctrine\DBAL\DBALException $e) {
echo date('Y-m-d H:i:s') . " - Erreur insertion $file = ".$e->getMessage()."\n";
}
}
else {
} else {
try {
$conn->update('sdv1.flux_insee', $data, array('id' => $fileRow->id));
}
catch(\Doctrine\DBAL\DBALException $e) {
} catch (\Doctrine\DBAL\DBALException $e) {
echo date('Y-m-d H:i:s') . " - Erreur update $file = ".$e->getMessage()."\n";
}
}
@ -180,8 +176,7 @@ if ($opts->cron || $oneShot) {
if ($execId !== null) {
$execRef->increment($execId, $unitExec);
}
}
else {
} else {
echo date('Y-m-d H:i:s') . " - Impossible de télécharger $file\n";
}
}