Skip to content

Commit

Permalink
Bug #6, stderr fix to bin/csv-import commandline PHP [iet:10277221]
Browse files Browse the repository at this point in the history
* [iet:10277034]
  • Loading branch information
nfreear committed Dec 11, 2017
1 parent 85e2b0c commit c0534db
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion bin/csv-import.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,10 @@
if (FANCY_PROGRESS) {
$bar->progress();
} else {
cli_write('.');
fwrite(STDERR, '.'); // Was: cli_write('.');
}
});
fwrite(STDERR, "\n");
if (FANCY_PROGRESS) {
$bar->end();
}
Expand Down
4 changes: 2 additions & 2 deletions db/User.php
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,8 @@ protected static function validateOucu($oucu, $row)
{
if (!preg_match(self::OUCU_REGEX, $oucu)) {
self::$warnings[] = [ 'row' => $row, 'msg' => 'Unexpected OUCU', 'oucu' => $oucu ];
echo 'W';
//throw new Exception('Unexpected OUCU format: ' . $oucu);
fwrite(STDERR, 'W'); // Was: echo 'W';
// Was: throw new Exception('Unexpected OUCU format: ' . $oucu);
}
return $oucu;
}
Expand Down

0 comments on commit c0534db

Please sign in to comment.