post.php: do not strip orientation metadata

This commit is contained in:
Zankaria 2024-04-03 19:51:58 +02:00
parent 6ceee8261e
commit eaacf27199

View File

@ -173,7 +173,7 @@ function ocr_image(array $config, string $img_path): string {
* @throws RuntimeException Throws on IO errors. * @throws RuntimeException Throws on IO errors.
*/ */
function strip_image_metadata(string $img_path): int { function strip_image_metadata(string $img_path): int {
$err = shell_exec_error('exiftool -overwrite_original -ignoreMinorErrors -q -q -all= ' . escapeshellarg($img_path)); $err = shell_exec_error('exiftool -overwrite_original -ignoreMinorErrors -q -q -all= -Orientation ' . escapeshellarg($img_path));
if ($err === false) { if ($err === false) {
throw new RuntimeException('Could not strip EXIF metadata!'); throw new RuntimeException('Could not strip EXIF metadata!');
} }