Update tutorial-core-validators.md

The maxSize validator validates in bytes, so the example was incorrect (it was 1GB instead of 1MB).
This commit is contained in:
Riyyi
2015-02-26 16:18:03 +01:00
parent cbda88a01c
commit 03d55e35ac

View File

@ -240,7 +240,7 @@ either a single column or multiple columns.
[
// checks if "primaryImage" is an uploaded image file in PNG, JPG or GIF format.
// the file size must be less than 1MB
['primaryImage', 'file', 'extensions' => ['png', 'jpg', 'gif'], 'maxSize' => 1024*1024*1024],
['primaryImage', 'file', 'extensions' => ['png', 'jpg', 'gif'], 'maxSize' => 1024*1024],
]
```