Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: method to download files easily #601

Merged
merged 2 commits into from
Jul 27, 2024
Merged

Conversation

pierresh
Copy link

This PR adds the method download() to download easily a file from the server.

Example:

$file = 'path/to/file.txt';

Flight::download($path);

@n0nag0n
Copy link
Collaborator

n0nag0n commented Jul 26, 2024

Thanks for creating this PR. When I get around to it, I'll have to change a bit of this code to conform to the contribution requirements (unit testing, syntax requirements, etc). For now I assume you're good with just keeping this as a Flight::map('download', ...); method in your project correct?

@pierresh
Copy link
Author

Yes, I can use map() for time being, thanks!

@n0nag0n
Copy link
Collaborator

n0nag0n commented Jul 27, 2024

Wanna look this over in case I missed anything?

@pierresh
Copy link
Author

I checked the code and ran the test, it looks good to me, thanks!

@n0nag0n n0nag0n merged commit c834f4c into flightphp:master Jul 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants