Skip to content

Commit

Permalink
Add support for paths in php-exif (#2490)
Browse files Browse the repository at this point in the history
  • Loading branch information
ildyria authored Jul 2, 2024
1 parent dcf54f0 commit 9065072
Show file tree
Hide file tree
Showing 4 changed files with 120 additions and 99 deletions.
4 changes: 2 additions & 2 deletions app/Metadata/Extractor.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,8 @@ public static function createFromFile(NativeLocalFile $file, int $fileLastModifi
// 3. Imagick (not for videos, i.e. for supported photos and accepted raw files only)
// 4. Native PHP exif reader (last resort)
$reader = match (true) {
(Configs::hasFFmpeg() && $isSupportedVideo) => Reader::factory(ReaderType::FFPROBE),
Configs::hasExiftool() => Reader::factory(ReaderType::EXIFTOOL),
(Configs::hasFFmpeg() && $isSupportedVideo) => Reader::factory(ReaderType::FFPROBE, Configs::getValueAsString('ffprobe_path')),
Configs::hasExiftool() => Reader::factory(ReaderType::EXIFTOOL, Configs::getValueAsString('exiftool_path')),
(Configs::hasImagick() && !$isSupportedVideo) => Reader::factory(ReaderType::IMAGICK),
default => Reader::factory(ReaderType::NATIVE),
};
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
"laravel/socialite": "^5.11",
"livewire/livewire": "^3.0",
"lychee-org/nestedset": "^9.0",
"lychee-org/php-exif": "^1.0.0",
"lychee-org/php-exif": "^1.0.4",
"maennchen/zipstream-php": "^3.1",
"opcodesio/log-viewer": "dev-lycheeOrg",
"php-ffmpeg/php-ffmpeg": "^1.0",
Expand Down
Loading

0 comments on commit 9065072

Please sign in to comment.