public function downloadFile($filename)
{
// Generate a temporary URL for the file download
$temporaryUrl = Storage::temporaryUrl(
"path/to/{$filename}",
now()->addMinutes(5) // Adjust the expiration time as per your requirement
);
// Return the download response
return response()->download($temporaryUrl, $filename)->deleteFileAfterSend();
}