Skip to content

Commit

Permalink
[phalcon#13208] - Trying interface corrections
Browse files Browse the repository at this point in the history
  • Loading branch information
niden committed Jun 20, 2019
1 parent ecde2b5 commit 975d1f7
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 8 deletions.
5 changes: 3 additions & 2 deletions phalcon/Validation/Validator/File.zep
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,9 @@ use Phalcon\Validation\Validator\File\Size\Min as MinFileSize;
*/
class File extends ValidatorComposite
{
private validators = [] {get};

/**
* Constructor
*/
public function __construct(array! options = [])
{
var included, key, message, validator, value;
Expand Down
8 changes: 4 additions & 4 deletions phalcon/Validation/Validator/File/FileAbstract.zep
Original file line number Diff line number Diff line change
Expand Up @@ -60,17 +60,17 @@ abstract class FileAbstract extends Validator
/**
* Empty is empty
*/
protected messageFileEmpty = "Field :field must not be empty" {get, set};
protected messageFileEmpty = "Field :field must not be empty" { get, set };

/**
* File exceeed the file size setted in PHP configuration
*/
protected messageIniSize = "File :field exceeds the maximum file size" {get, set};
protected messageIniSize = "File :field exceeds the maximum file size" { get, set };

/**
* File is not valid
*/
protected messageValid = "Field :field is not valid" {get, set};
protected messageValid = "Field :field is not valid" { get, set };

/**
* Check on empty
Expand Down Expand Up @@ -238,4 +238,4 @@ abstract class FileAbstract extends Validator

return floatval(matches[1]) * pow(2, byteUnits[unit]);
}
}
}
5 changes: 3 additions & 2 deletions phalcon/Validation/Validator/StringLength.zep
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,9 @@ use Phalcon\Validation\Exception;
*/
class StringLength extends ValidatorComposite
{
private validators = [] {get};

/**
* Constructor
*/
public function __construct(array! options = []) -> void
{
var included, key, message, validator, value;
Expand Down
5 changes: 5 additions & 0 deletions phalcon/Validation/ValidatorComposite.zep
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@ namespace Phalcon\Validation;
*/
abstract class ValidatorComposite extends Validator implements ValidatorCompositeInterface
{
/**
* @var array
*/
private validators = [] { get };

/**
* Executes the validation
*/
Expand Down

0 comments on commit 975d1f7

Please sign in to comment.