Passed
Push — develop ( 448334...a47dcf )
by nguereza
02:20
created
src/RuleInterface.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -50,8 +50,7 @@
 block discarded – undo
50 50
  * A generic Rule that asserts whether the given validation
51 51
  * data is valid or not.
52 52
  */
53
-interface RuleInterface
54
-{
53
+interface RuleInterface {
55 54
 
56 55
     /**
57 56
      * Method to validate this Rule
Please login to merge, or discard this patch.
src/Rule/Date.php 2 patches
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -49,8 +49,7 @@  discard block
 block discarded – undo
49 49
 use Platine\Validator\RuleInterface;
50 50
 use Platine\Validator\Validator;
51 51
 
52
-class Date implements RuleInterface
53
-{
52
+class Date implements RuleInterface {
54 53
 
55 54
     /**
56 55
      * The date format to validate
@@ -62,8 +61,7 @@  discard block
 block discarded – undo
62 61
      * Constructor
63 62
      * @param string $format the date format
64 63
      */
65
-    public function __construct(string $format)
66
-    {
64
+    public function __construct(string $format) {
67 65
         $this->format = $format;
68 66
     }
69 67
 
Please login to merge, or discard this patch.
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@
 block discarded – undo
73 73
      */
74 74
     public function validate(string $field, $value, Validator $validator): bool
75 75
     {
76
-		if (empty($value)) {
76
+        if (empty($value)) {
77 77
             return true;
78 78
         }
79 79
         $dateValue = date_create_from_format($this->format, (string) $value);
Please login to merge, or discard this patch.
src/Rule/Range.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -49,8 +49,7 @@  discard block
 block discarded – undo
49 49
 use Platine\Validator\RuleInterface;
50 50
 use Platine\Validator\Validator;
51 51
 
52
-class Range implements RuleInterface
53
-{
52
+class Range implements RuleInterface {
54 53
 
55 54
     /**
56 55
      * Minimum Value to compare against
@@ -69,8 +68,7 @@  discard block
 block discarded – undo
69 68
      * @param mixed $min the minimum value to compare against
70 69
      * @param mixed $max the maximum value to compare against
71 70
      */
72
-    public function __construct($min, $max)
73
-    {
71
+    public function __construct($min, $max) {
74 72
         $this->min = $min;
75 73
         $this->max = $max;
76 74
     }
Please login to merge, or discard this patch.
src/Rule/AlphaNumericDash.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -49,8 +49,7 @@
 block discarded – undo
49 49
 use Platine\Validator\RuleInterface;
50 50
 use Platine\Validator\Validator;
51 51
 
52
-class AlphaNumericDash implements RuleInterface
53
-{
52
+class AlphaNumericDash implements RuleInterface {
54 53
 
55 54
     /**
56 55
      * String pattern to allow
Please login to merge, or discard this patch.
src/Rule/NotEqual.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -49,8 +49,7 @@  discard block
 block discarded – undo
49 49
 use Platine\Validator\RuleInterface;
50 50
 use Platine\Validator\Validator;
51 51
 
52
-class NotEqual implements RuleInterface
53
-{
52
+class NotEqual implements RuleInterface {
54 53
 
55 54
     /**
56 55
      * Value to compare against
@@ -62,8 +61,7 @@  discard block
 block discarded – undo
62 61
      * Constructor
63 62
      * @param mixed $value the value to compare against
64 63
      */
65
-    public function __construct($value)
66
-    {
64
+    public function __construct($value) {
67 65
         $this->value = $value;
68 66
     }
69 67
 
Please login to merge, or discard this patch.
src/Rule/Integer.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -49,8 +49,7 @@
 block discarded – undo
49 49
 use Platine\Validator\RuleInterface;
50 50
 use Platine\Validator\Validator;
51 51
 
52
-class Integer implements RuleInterface
53
-{
52
+class Integer implements RuleInterface {
54 53
 
55 54
     /**
56 55
      * {@inheritdoc}
Please login to merge, or discard this patch.
src/Rule/Regex.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -49,8 +49,7 @@  discard block
 block discarded – undo
49 49
 use Platine\Validator\RuleInterface;
50 50
 use Platine\Validator\Validator;
51 51
 
52
-class Regex implements RuleInterface
53
-{
52
+class Regex implements RuleInterface {
54 53
 
55 54
     /**
56 55
      * The regex pattern
@@ -62,8 +61,7 @@  discard block
 block discarded – undo
62 61
      * Constructor
63 62
      * @param string $regex the regex pattern
64 63
      */
65
-    public function __construct(string $regex)
66
-    {
64
+    public function __construct(string $regex) {
67 65
         $this->regex = $regex;
68 66
     }
69 67
 
Please login to merge, or discard this patch.
src/Rule/URL.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -49,8 +49,7 @@
 block discarded – undo
49 49
 use Platine\Validator\RuleInterface;
50 50
 use Platine\Validator\Validator;
51 51
 
52
-class URL implements RuleInterface
53
-{
52
+class URL implements RuleInterface {
54 53
 
55 54
     /**
56 55
      * {@inheritdoc}
Please login to merge, or discard this patch.
src/Rule/ExactLength.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -49,8 +49,7 @@  discard block
 block discarded – undo
49 49
 use Platine\Validator\RuleInterface;
50 50
 use Platine\Validator\Validator;
51 51
 
52
-class ExactLength implements RuleInterface
53
-{
52
+class ExactLength implements RuleInterface {
54 53
 
55 54
     /**
56 55
      * The length
@@ -62,8 +61,7 @@  discard block
 block discarded – undo
62 61
      * Constructor
63 62
      * @param int $length
64 63
      */
65
-    public function __construct(int $length)
66
-    {
64
+    public function __construct(int $length) {
67 65
         $this->length = $length;
68 66
     }
69 67
 
Please login to merge, or discard this patch.