FileStorage.php 425 B

12345678910111213141516171819202122
  1. <?php
  2. declare(strict_types=1);
  3. namespace App\Service\Storage;
  4. use App\Service\Utils\Path;
  5. use Knp\Bundle\GaufretteBundle\FilesystemMap;
  6. /**
  7. * Base class for file storage
  8. */
  9. abstract class FileStorage
  10. {
  11. public function __construct(
  12. protected FilesystemMap $filesystem
  13. )
  14. {}
  15. protected function getStorageBaseDir(): string {
  16. return Path::join(Path::getProjectDir(), 'var', 'files');
  17. }
  18. }