WIP
This commit is contained in:
@@ -4,7 +4,6 @@ namespace App\Services;
|
||||
|
||||
use App\ImportsMedia;
|
||||
use App\Models\Album;
|
||||
use Illuminate\Foundation\Bus\PendingChain;
|
||||
use Illuminate\Http\UploadedFile;
|
||||
use Symfony\Component\HttpKernel\Exception\UnsupportedMediaTypeHttpException;
|
||||
|
||||
@@ -17,10 +16,11 @@ class MediaImporter {
|
||||
}
|
||||
}
|
||||
|
||||
public function import(UploadedFile $file, Album $location): array {
|
||||
public function import(UploadedFile $file, Album $location): void {
|
||||
foreach ($this->importers as $importer) {
|
||||
if($importer::supports($file)) {
|
||||
return (new $importer($file, $location))->import();
|
||||
(new $importer($file, $location))->import();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user