le mode par défaut est w+b pour file::writer

This commit is contained in:
Jephté Clain 2024-11-15 11:09:31 +04:00
parent 0593c3ed9d
commit 7742c2d330
1 changed files with 1 additions and 1 deletions

View File

@ -29,7 +29,7 @@ class file {
return $file; return $file;
} }
static function writer($output, ?string $mode=null, ?callable $func=null): FileWriter { static function writer($output, ?string $mode="w+b", ?callable $func=null): FileWriter {
$file = new FileWriter(self::fix_dash($output), $mode); $file = new FileWriter(self::fix_dash($output), $mode);
if ($func !== null) { if ($func !== null) {
try { try {