Passed
Push — develop ( 6b5814...6f2a0b )
by nguereza
09:03 queued 06:40
created
src/Storage/LocalStorage.php 3 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -62,10 +62,10 @@
 block discarded – undo
62 62
  */
63 63
 class LocalStorage extends AbstractStorage
64 64
 {
65
-     /**
66
-     * The directory to use to save files
67
-     * @var DirectoryInterface
68
-     */
65
+        /**
66
+         * The directory to use to save files
67
+         * @var DirectoryInterface
68
+         */
69 69
     protected DirectoryInterface $directory;
70 70
 
71 71
     /**
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -103,7 +103,7 @@
 block discarded – undo
103 103
      * {@inheritdoc}
104 104
      * @see SessionHandlerInterface
105 105
      */
106
-    public function read(string $sid): string|false
106
+    public function read(string $sid): string | false
107 107
     {
108 108
         $file = $this->getSessionFile($sid);
109 109
 
Please login to merge, or discard this patch.
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -60,8 +60,7 @@  discard block
 block discarded – undo
60 60
  * @class LocalStorage
61 61
  * @package Platine\Session\Storage
62 62
  */
63
-class LocalStorage extends AbstractStorage
64
-{
63
+class LocalStorage extends AbstractStorage {
65 64
      /**
66 65
      * The directory to use to save files
67 66
      * @var DirectoryInterface
@@ -80,8 +79,7 @@  discard block
 block discarded – undo
80 79
      * @param Configuration|null $config
81 80
      * @throws FileSessionHandlerException
82 81
      */
83
-    public function __construct(Filesystem $filesystem, ?Configuration $config = null)
84
-    {
82
+    public function __construct(Filesystem $filesystem, ?Configuration $config = null) {
85 83
         parent::__construct($config);
86 84
 
87 85
         $path = $this->config->get('storages.file.path');
Please login to merge, or discard this patch.
src/Session.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -233,8 +233,8 @@
 block discarded – undo
233 233
             session_name($sessionName);
234 234
         }
235 235
 
236
-        $ttl = (int)$this->config->get('ttl');
237
-        $lifetime = (int)$this->config->get('cookie.lifetime');
236
+        $ttl = (int) $this->config->get('ttl');
237
+        $lifetime = (int) $this->config->get('cookie.lifetime');
238 238
         $path = $this->config->get('cookie.path');
239 239
         $domain = $this->config->get('cookie.domain');
240 240
         $secure = $this->config->get('cookie.secure');
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -52,8 +52,7 @@
 block discarded – undo
52 52
 use Platine\Stdlib\Helper\Arr;
53 53
 use SessionHandlerInterface;
54 54
 
55
-class Session
56
-{
55
+class Session {
57 56
     /**
58 57
      * The session driver to use
59 58
      * @var SessionHandlerInterface
Please login to merge, or discard this patch.
src/Storage/AbstractStorage.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -67,8 +67,7 @@
 block discarded – undo
67 67
      * Create new instance
68 68
      * @param Configuration|null $config
69 69
      */
70
-    public function __construct(?Configuration $config = null)
71
-    {
70
+    public function __construct(?Configuration $config = null) {
72 71
         $this->config = $config ?? new Configuration([]);
73 72
     }
74 73
 
Please login to merge, or discard this patch.
src/Configuration.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 Configuration
54 54
  * @package Platine\Session
55 55
  */
56
-class Configuration extends AbstractConfiguration
57
-{
56
+class Configuration extends AbstractConfiguration {
58 57
     /**
59 58
      * {@inheritdoc}
60 59
      */
Please login to merge, or discard this patch.
src/Exception/FileSessionHandlerException.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,6 +37,5 @@
 block discarded – undo
37 37
  * @class FileSessionHandlerException
38 38
  * @package Platine\Session\Exception
39 39
  */
40
-class FileSessionHandlerException extends SessionException
41
-{
40
+class FileSessionHandlerException extends SessionException {
42 41
 }
Please login to merge, or discard this patch.
src/Exception/SessionException.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -39,6 +39,5 @@
 block discarded – undo
39 39
  * @class SessionException
40 40
  * @package Platine\Session\Exception
41 41
  */
42
-class SessionException extends Exception
43
-{
42
+class SessionException extends Exception {
44 43
 }
Please login to merge, or discard this patch.
src/Storage/NullStorage.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@
 block discarded – undo
57 57
      * {@inheritdoc}
58 58
      * @see SessionHandlerInterface
59 59
      */
60
-    public function read(string $sid): string|false
60
+    public function read(string $sid): string | false
61 61
     {
62 62
         return '';
63 63
     }
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -51,8 +51,7 @@
 block discarded – undo
51 51
  * @class NullStorage
52 52
  * @package Platine\Session\Storage
53 53
  */
54
-class NullStorage extends AbstractStorage
55
-{
54
+class NullStorage extends AbstractStorage {
56 55
     /**
57 56
      * {@inheritdoc}
58 57
      * @see SessionHandlerInterface
Please login to merge, or discard this patch.
src/Storage/ApcuStorage.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@
 block discarded – undo
76 76
      * {@inheritdoc}
77 77
      * @see SessionHandlerInterface
78 78
      */
79
-    public function read(string $sid): string|false
79
+    public function read(string $sid): string | false
80 80
     {
81 81
         $success = false;
82 82
         /** @var mixed */
Please login to merge, or discard this patch.
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -55,15 +55,13 @@
 block discarded – undo
55 55
  * @class ApcuStorage
56 56
  * @package Platine\Session\Storage
57 57
  */
58
-class ApcuStorage extends AbstractStorage
59
-{
58
+class ApcuStorage extends AbstractStorage {
60 59
     /**
61 60
      * {@inheritdoc}
62 61
      *
63 62
      * Create new instance
64 63
      */
65
-    public function __construct(?Configuration $config = null)
66
-    {
64
+    public function __construct(?Configuration $config = null) {
67 65
         if ((!extension_loaded('apcu')) || !((bool) ini_get('apc.enabled'))) {
68 66
             throw new SessionException('The session for APCu driver is not available.'
69 67
                             . ' Check if APCu extension is loaded and enabled.');
Please login to merge, or discard this patch.