Passed
Push — develop ( 4d6c26...26b299 )
by nguereza
11:28
created
src/CookieManager.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -53,8 +53,7 @@  discard block
 block discarded – undo
53 53
  * @class CookieManager
54 54
  * @package Platine\Cookie
55 55
  */
56
-class CookieManager implements CookieManagerInterface
57
-{
56
+class CookieManager implements CookieManagerInterface {
58 57
     /**
59 58
      * The cookies
60 59
      * @var CookieInterface[]
@@ -65,8 +64,7 @@  discard block
 block discarded – undo
65 64
      * Create new instance
66 65
      * @param CookieInterface[] $cookies the default cookies to store
67 66
      */
68
-    public function __construct(array $cookies = [])
69
-    {
67
+    public function __construct(array $cookies = []) {
70 68
         foreach ($cookies as $cookie) {
71 69
             $this->add($cookie);
72 70
         }
Please login to merge, or discard this patch.
src/Middleware/CookieSendMiddleware.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -57,8 +57,7 @@
 block discarded – undo
57 57
  * @class CookieSendMiddleware
58 58
  * @package Platine\Cookie\Middleware
59 59
  */
60
-class CookieSendMiddleware implements MiddlewareInterface
61
-{
60
+class CookieSendMiddleware implements MiddlewareInterface {
62 61
     /**
63 62
      * Create new instance
64 63
      * @param CookieManagerInterface $cookies The cookie manager instance
Please login to merge, or discard this patch.
src/CookieManagerInterface.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -53,8 +53,7 @@
 block discarded – undo
53 53
  * @class CookieManagerInterface
54 54
  * @package Platine\Cookie
55 55
  */
56
-interface CookieManagerInterface
57
-{
56
+interface CookieManagerInterface {
58 57
     /**
59 58
      * Set the cookie
60 59
      *
Please login to merge, or discard this patch.
src/CookieInterface.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -150,7 +150,7 @@
 block discarded – undo
150 150
      *
151 151
      * @return CookieInterface
152 152
      */
153
-    public function withExpires(int|string|DateTimeInterface|null $expire = null): self;
153
+    public function withExpires(int | string | DateTimeInterface | null $expire = null): self;
154 154
 
155 155
     /**
156 156
      * Return the domain of the cookie
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -60,8 +60,7 @@
 block discarded – undo
60 60
  * change state MUST be implemented such that they retain the internal state of
61 61
  * the current instance and return an instance that contains the changed state.
62 62
  */
63
-interface CookieInterface extends Stringable
64
-{
63
+interface CookieInterface extends Stringable {
65 64
     /**
66 65
      * Same site policy "None"
67 66
      */
Please login to merge, or discard this patch.
src/Cookie.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -129,7 +129,7 @@  discard block
 block discarded – undo
129 129
     public function __construct(
130 130
         string $name,
131 131
         string $value = '',
132
-        int|string|DateTimeInterface|null $expire = null,
132
+        int | string | DateTimeInterface | null $expire = null,
133 133
         ?string $domain = null,
134 134
         ?string $path = '/',
135 135
         ?bool $secure = true,
@@ -223,7 +223,7 @@  discard block
 block discarded – undo
223 223
     /**
224 224
      * {@inheritdoc}
225 225
      */
226
-    public function withExpires(int|string|DateTimeInterface|null $expire = null): self
226
+    public function withExpires(int | string | DateTimeInterface | null $expire = null): self
227 227
     {
228 228
         if ($expire === $this->expires) {
229 229
             return $this;
@@ -440,7 +440,7 @@  discard block
 block discarded – undo
440 440
      * Set the cookie expires
441 441
      * @param int|string|DateTimeInterface|null $expire
442 442
      */
443
-    private function setExpires(int|string|DateTimeInterface|null $expire): self
443
+    private function setExpires(int | string | DateTimeInterface | null $expire): self
444 444
     {
445 445
         if ($expire === null || (is_string($expire) && empty($expire))) {
446 446
             $expire = 0;
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -54,8 +54,7 @@
 block discarded – undo
54 54
  * @class Cookie
55 55
  * @package Platine\Cookie
56 56
  */
57
-class Cookie implements CookieInterface
58
-{
57
+class Cookie implements CookieInterface {
59 58
     /**
60 59
      * The name of the cookie
61 60
      *
Please login to merge, or discard this patch.