Fixed the logger

This commit is contained in:
Lewis Dale committed 2023-08-27 21:32:27 +01:00
1 parent 69d8ec33a5
commit 16e0a8f381
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -15,7 +15,7 @@ class FileLogger extends AbstractLogger
$callingClass = debug_backtrace()[2]['class'];
$callingFunction = debug_backtrace()[2]['function'];
$log = $timestamp->format(DATE_ATOM) . " [$level] $callingClass::$callingFunction $message " . json_encode($context);
fwrite(fopen($this->filename, 'w'), $log . PHP_EOL);
fwrite(fopen($this->filename, 'a'), $log . PHP_EOL);
}
}
+1 -1
View File
@@ -39,7 +39,7 @@ class Resizer
$params,
$converted
);
$this->logger->info("Saved image for $path");
$this->logger->info("Saved image", ['path'=>$path, 'params'=>$params]);
header("Content-type: {$original_img->getMime()}");
return base64_decode($converted);