Skip to content

A self-hosted media server and file management system

fix: infinite bitrate checks for audio files without bitrate

aminnausin02d8a4778ecd
diff --git a/app/Jobs/VerifyFiles.php b/app/Jobs/VerifyFiles.php
index 5819377b..975bf8b0 100755
--- a/app/Jobs/VerifyFiles.php
+++ b/app/Jobs/VerifyFiles.php
@@ -184,8 +184,8 @@ class VerifyFiles extends ManagedSubTask {
if ($stored['media_type'] !== $media_type) {
$changes['media_type'] = $media_type;
}
- // if file is of type audio and one of the following is true: artist is null, album is null, codec is null, bitrate is null => generate description from audio tags
- $audioMetadata = ($fileUpdated || is_null($metadata->artist) || is_null($metadata->album) || is_null($metadata->bitrate) || is_null($metadata->codec)) && $is_audio ? $this->getAudioDescription($filePath, $this->fileMetaData ?? null) : [];
+ // if file is of type audio and one of the following is true: artist is null, album is null, codec is null => generate description from audio tags
+ $audioMetadata = ($fileUpdated || is_null($metadata->artist) || is_null($metadata->album) || is_null($metadata->codec)) && $is_audio ? $this->getAudioDescription($filePath, $this->fileMetaData ?? null) : [];
// TODO: if no poster_url is set or file was modified since last update and the file is of type audio, extract image
// TODO: if poster_url is set and it is not a local url, download and save as local image