laravel storage exists returns false although file exists

  exists, file, laravel, php, storage

I am modifying an uploaded pdf with Fpdi, in laravel.
The pdf is generated perfectly, I can see it in any file explorer. But laravel built in Storage::exists() returns false.
It is a pretty weird error, because php file_exists method can find the file perfectly with the same path.

I am completely out of ideas. Any help would be appriciated!

Storage::disk('public')->exists($src); //this returns false
file_exists($src); //this returns true

Source: Laravel

Leave a Reply