Skip to content

[HttpFoundation] split FileException into specialized ones about upload handling #26475

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

Merged
merged 1 commit into from
Apr 3, 2018
Merged

[HttpFoundation] split FileException into specialized ones about upload handling #26475

merged 1 commit into from
Apr 3, 2018

Conversation

fmata
Copy link
Contributor

@fmata fmata commented Mar 9, 2018

Q A
Branch? master
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #26411
License MIT

@nicolas-grekas nicolas-grekas changed the title [HttpFoundation] split FileException into specialized ones about uplo… [HttpFoundation] split FileException into specialized ones about upload handling Mar 12, 2018
@nicolas-grekas nicolas-grekas added this to the 4.1 milestone Mar 12, 2018
Copy link
Contributor

@soullivaneuh soullivaneuh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks! 👍

*
* @author Florent Mata <florentmata@gmail.com>
*/
class CantWriteFileException extends FileException
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would nose Cant here but Cannot instead.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wanted to follow the PHP const UPLOAD_ERR_CANT_WRITE to keep consistency, as others exceptions added in this PR. Are you sure of this change ?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@fmata can you please do the change? (and rebase meanwhile to fix the small conflict)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nicolas-grekas rebased & updated

namespace Symfony\Component\HttpFoundation\File\Exception;

/**
* Thrown when an error UPLOAD_ERR_CANT_WRITE occurred with UploadedFile.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would swap the word "error" and the name of the error.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated

@fmata
Copy link
Contributor Author

fmata commented Apr 2, 2018

Status: Needs Review

@fabpot
Copy link
Member

fabpot commented Apr 3, 2018

Thank you @fmata.

@fabpot fabpot merged commit 9e586cc into symfony:master Apr 3, 2018
fabpot added a commit that referenced this pull request Apr 3, 2018
…ones about upload handling (fmata)

This PR was merged into the 4.1-dev branch.

Discussion
----------

[HttpFoundation] split FileException into specialized ones about upload handling

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #26411
| License       | MIT

Commits
-------

9e586cc [HttpFoundation] split FileException into specialized ones about upload handling
@fmata fmata deleted the fileexception-split branch April 3, 2018 06:07
@fabpot fabpot mentioned this pull request May 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants