Working in laravel 5.3 and want to delete file in case of error here is my code
if(File::exists($file_destination.$file_name)){
echo "exists";
dd(File::delete($file_destination.$file_name));
}else{
dd('File is not exists.');
}
It prints exists and false for delete
I also try to use Unlink method but in that case it gives error permission denied Please help to fix thanks