mirror of
https://github.com/koel/koel
synced 2025-01-11 04:08:45 +00:00
21 lines
340 B
PHP
21 lines
340 B
PHP
|
<?php
|
||
|
|
||
|
namespace App\Services;
|
||
|
|
||
|
use App\Models\Song;
|
||
|
|
||
|
class TranscodingService
|
||
|
{
|
||
|
/**
|
||
|
* Determine if a song should be transcoded.
|
||
|
*
|
||
|
* @param Song $song
|
||
|
*
|
||
|
* @return bool
|
||
|
*/
|
||
|
public function songShouldBeTranscoded(Song $song)
|
||
|
{
|
||
|
return ends_with(mime_content_type($song->path), 'flac');
|
||
|
}
|
||
|
}
|