Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel Neto committed Feb 12, 2025
1 parent db4c502 commit ed308d6
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions objects/video.php
Original file line number Diff line number Diff line change
Expand Up @@ -4931,6 +4931,9 @@ public static function getVideosPaths($filename, $includeS3 = false, $try = 0)
if (!file_exists($tmpCacheFile)) {
file_put_contents($tmpCacheFile, json_encode($cache));
}
if(!empty($_REQUEST['debug'])){
_error_log("getVideosPaths($filename) line=".__LINE__);
}
return $obj;
} elseif (empty($global['disableAsyncGetVideosPaths']) && file_exists($tmpCacheFile)) {
_error_log("getVideosPaths($filename) 1 tmpCacheFile=$tmpCacheFile " . json_encode(ObjectYPT::getLastUsedCacheInfo()));
Expand All @@ -4940,6 +4943,9 @@ public static function getVideosPaths($filename, $includeS3 = false, $try = 0)

// Return the temporary cache file content if it exists
$tmpCacheContent = file_get_contents($tmpCacheFile);
if(!empty($_REQUEST['debug'])){
_error_log("getVideosPaths($filename) line=".__LINE__);
}
return object_to_array(_json_decode($tmpCacheContent));
} else {
// Call the function to generate the video paths
Expand All @@ -4953,6 +4959,9 @@ public static function getVideosPaths($filename, $includeS3 = false, $try = 0)
// Save the results in the main cache
$resp = $videoCache->setCache($videos);
//_error_log("getVideosPaths($filename) 2 ".json_encode($resp));
if(!empty($_REQUEST['debug'])){
_error_log("getVideosPaths($filename) line=".__LINE__);
}
return $videos;
}
}
Expand Down

0 comments on commit ed308d6

Please sign in to comment.