mirror of
https://github.com/Poniverse/Pony.fm.git
synced 2024-11-25 14:37:59 +01:00
Merge rPF207569e5978d: T357: Ignore WMA files and added support for FLAC imports.
This commit is contained in:
parent
2ac9fd6967
commit
9468ced8c4
1 changed files with 8 additions and 6 deletions
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
namespace App\Console\Commands;
|
namespace App\Console\Commands;
|
||||||
|
|
||||||
|
use App\Album;
|
||||||
use App\Commands\UploadTrackCommand;
|
use App\Commands\UploadTrackCommand;
|
||||||
use App\Genre;
|
use App\Genre;
|
||||||
use App\Image;
|
use App\Image;
|
||||||
|
@ -41,7 +42,7 @@ class ImportMLPMA extends Command
|
||||||
*
|
*
|
||||||
* @var array
|
* @var array
|
||||||
*/
|
*/
|
||||||
protected $ignoredExtensions = ['db', 'jpg', 'png', 'txt', 'rtf'];
|
protected $ignoredExtensions = ['db', 'jpg', 'png', 'txt', 'rtf', 'wma'];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Used to stop the import process when a SIGINT is received.
|
* Used to stop the import process when a SIGINT is received.
|
||||||
|
@ -159,12 +160,13 @@ class ImportMLPMA extends Command
|
||||||
} elseif (Str::lower($file->getExtension()) === 'm4a') {
|
} elseif (Str::lower($file->getExtension()) === 'm4a') {
|
||||||
list($parsedTags, $rawTags) = $this->getAtomTags($allTags);
|
list($parsedTags, $rawTags) = $this->getAtomTags($allTags);
|
||||||
|
|
||||||
} else {
|
} elseif (Str::lower($file->getExtension()) === 'ogg') {
|
||||||
if (Str::lower($file->getExtension()) === 'ogg') {
|
|
||||||
list($parsedTags, $rawTags) = $this->getVorbisTags($allTags);
|
list($parsedTags, $rawTags) = $this->getVorbisTags($allTags);
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
} elseif (Str::lower($file->getExtension()) === 'flac') {
|
||||||
|
list($parsedTags, $rawTags) = $this->getVorbisTags($allTags);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
//==========================================================================================================
|
//==========================================================================================================
|
||||||
// Determine the release date.
|
// Determine the release date.
|
||||||
|
|
Loading…
Reference in a new issue