Completed
Push — master ( 40fd9b...865340 )
by Joachim
03:19
created
src/Payload/Payload.php 1 patch
Doc Comments   +19 added lines patch added patch discarded remove patch
@@ -30,6 +30,9 @@  discard block
 block discarded – undo
30 30
         return $payload;
31 31
     }
32 32
 
33
+    /**
34
+     * @param string $val
35
+     */
33 36
     final protected function assertString($val)
34 37
     {
35 38
         if (is_string($val)) {
@@ -39,6 +42,9 @@  discard block
 block discarded – undo
39 42
         throw $this->createAssertionException($val, 'Expected string');
40 43
     }
41 44
 
45
+    /**
46
+     * @param string $val
47
+     */
42 48
     final protected function assertStringOrNull($val)
43 49
     {
44 50
         if (is_null($val) || is_string($val)) {
@@ -48,6 +54,9 @@  discard block
 block discarded – undo
48 54
         throw $this->createAssertionException($val, 'Expected null or string');
49 55
     }
50 56
 
57
+    /**
58
+     * @param double $val
59
+     */
51 60
     final protected function assertNumeric($val)
52 61
     {
53 62
         if (is_int($val) || is_float($val)) {
@@ -57,6 +66,9 @@  discard block
 block discarded – undo
57 66
         throw $this->createAssertionException($val, 'Expected int or float');
58 67
     }
59 68
 
69
+    /**
70
+     * @param double $val
71
+     */
60 72
     final protected function assertNumericOrNull($val)
61 73
     {
62 74
         if (is_null($val) || is_float($val) || is_int($val)) {
@@ -75,6 +87,10 @@  discard block
 block discarded – undo
75 87
         throw $this->createAssertionException($val, 'Expected value to be in array ['.join(', ', $arr).']');
76 88
     }
77 89
 
90
+    /**
91
+     * @param string $val
92
+     * @param string[] $arr
93
+     */
78 94
     final protected function assertInArrayOrNull($val, $arr)
79 95
     {
80 96
         if (is_null($val) || in_array($val, $arr)) {
@@ -93,6 +109,9 @@  discard block
 block discarded – undo
93 109
         throw $this->createAssertionException($val, 'Expected \DateTimeInterface');
94 110
     }
95 111
 
112
+    /**
113
+     * @param \DateTimeInterface $val
114
+     */
96 115
     final protected function assertDateTimeOrNull($val)
97 116
     {
98 117
         if (is_null($val) || $val instanceof \DateTimeInterface) {
Please login to merge, or discard this patch.
src/Client.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
         $baseUrl = $parsedBaseUrl['scheme'].
48 48
             '://'.rawurlencode($this->username).':'.rawurlencode($this->password).'@'.$parsedBaseUrl['host'];
49 49
 
50
-        $this->baseUrl  = $baseUrl;
50
+        $this->baseUrl = $baseUrl;
51 51
     }
52 52
 
53 53
     /**
@@ -197,7 +197,7 @@  discard block
 block discarded – undo
197 197
     {
198 198
 
199 199
         $url = $this->baseUrl.$uri;
200
-        $options = $options ? : [];
200
+        $options = $options ?: [];
201 201
         $defaultOptions = [];
202 202
         $options = array_merge($defaultOptions, $options);
203 203
         $client = $this->getClient();
Please login to merge, or discard this patch.