mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-03 09:49:28 +02:00
This commit is contained in:
parent
dfe7b798f1
commit
943fcff6b9
1 changed files with 8 additions and 3 deletions
|
@ -11,6 +11,9 @@ $path = getVideosDir();
|
||||||
$total = Video::getTotalVideos("", false, true, true, false, false);
|
$total = Video::getTotalVideos("", false, true, true, false, false);
|
||||||
$videos = Video::getAllVideosLight("", false, true, false);
|
$videos = Video::getAllVideosLight("", false, true, false);
|
||||||
$count = 0;
|
$count = 0;
|
||||||
|
|
||||||
|
$isStorage = isAnyStorageEnabled();
|
||||||
|
|
||||||
foreach ($videos as $value) {
|
foreach ($videos as $value) {
|
||||||
$count++;
|
$count++;
|
||||||
|
|
||||||
|
@ -19,9 +22,11 @@ foreach ($videos as $value) {
|
||||||
$dirname = $basename.DIRECTORY_SEPARATOR;
|
$dirname = $basename.DIRECTORY_SEPARATOR;
|
||||||
foreach ($glob as $file) {
|
foreach ($glob as $file) {
|
||||||
if (is_dir($file)) {
|
if (is_dir($file)) {
|
||||||
|
if(!$isStorage){
|
||||||
//echo $file.PHP_EOL;
|
//echo $file.PHP_EOL;
|
||||||
$move = Video::updateDirectoryFilename($file);
|
$move = Video::updateDirectoryFilename($file);
|
||||||
echo "-->".PHP_EOL." {$count}/{$total} move directory {$move['oldDir']} to {$move['newDir']} ".PHP_EOL."<--" . PHP_EOL . PHP_EOL;
|
echo "-->".PHP_EOL." {$count}/{$total} move directory {$move['oldDir']} to {$move['newDir']} ".PHP_EOL."<--" . PHP_EOL . PHP_EOL;
|
||||||
|
}
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
$filename = basename($file);
|
$filename = basename($file);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue