symfony/symfony — pull request #2508 by stealth35 (2011-10-28 13:40:15+00:00)
Title: [Validators] extension constraint for FileValidator

Bug fix: no
Feature addition: yes
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: -

Add extension constraint for FileValidator,

For example :
When your waiting a CSV file the mimetype is `text/plain` not `text/csv`, so it's good to double checking with the extension (`csv`), same thing with an Open Office Calc file who render an `application/xml` (extension `ods`)