Completed
Branch feature/pre-split (60f5c0)
by Anton
03:19
created
source/Spiral/Cache/CacheManager.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -65,7 +65,7 @@
 block discarded – undo
65 65
         }
66 66
 
67 67
         if (!$store->isAvailable()) {
68
-            throw new CacheException("Unable to mount unavailable store '" . get_class($store) . "'");
68
+            throw new CacheException("Unable to mount unavailable store '".get_class($store)."'");
69 69
         }
70 70
 
71 71
         $this->stores[$name] = $store;
Please login to merge, or discard this patch.
source/Spiral/Cache/Stores/FileStore.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
      *
83 83
      * @param int $expiration Current expiration time value in seconds (reference).
84 84
      */
85
-    public function get(string $name, int &$expiration = null)
85
+    public function get(string $name, int & $expiration = null)
86 86
     {
87 87
         if (!$this->files->exists($filename = $this->makeFilename($name))) {
88 88
             return null;
@@ -179,6 +179,6 @@  discard block
 block discarded – undo
179 179
      */
180 180
     protected function makeFilename(string $name): string
181 181
     {
182
-        return $this->directory . md5($name) . '.' . $this->extension;
182
+        return $this->directory.md5($name).'.'.$this->extension;
183 183
     }
184 184
 }
Please login to merge, or discard this patch.
source/Spiral/Cache/Stores/MemcacheStore.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
      */
92 92
     public function has(string $name): bool
93 93
     {
94
-        return $this->driver->get($this->prefix . $name);
94
+        return $this->driver->get($this->prefix.$name);
95 95
     }
96 96
 
97 97
     /**
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
      */
100 100
     public function get(string $name)
101 101
     {
102
-        return $this->driver->get($this->prefix . $name);
102
+        return $this->driver->get($this->prefix.$name);
103 103
     }
104 104
 
105 105
     /**
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
             $ttl = 0;
115 115
         }
116 116
 
117
-        return $this->driver->set($this->prefix . $name, $data, $ttl);
117
+        return $this->driver->set($this->prefix.$name, $data, $ttl);
118 118
     }
119 119
 
120 120
     /**
@@ -122,7 +122,7 @@  discard block
 block discarded – undo
122 122
      */
123 123
     public function delete(string $name)
124 124
     {
125
-        return $this->driver->delete($this->prefix . $name);
125
+        return $this->driver->delete($this->prefix.$name);
126 126
     }
127 127
 
128 128
     /**
@@ -130,7 +130,7 @@  discard block
 block discarded – undo
130 130
      */
131 131
     public function inc(string $name, int $delta = 1): int
132 132
     {
133
-        return $this->driver->inc($this->prefix . $name);
133
+        return $this->driver->inc($this->prefix.$name);
134 134
     }
135 135
 
136 136
     /**
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
      */
139 139
     public function dec(string $name, int $delta = 1): int
140 140
     {
141
-        return $this->driver->dec($this->prefix . $name, $delta);
141
+        return $this->driver->dec($this->prefix.$name, $delta);
142 142
     }
143 143
 
144 144
     /**
Please login to merge, or discard this patch.
source/Spiral/Cache/Stores/APCStore.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -69,10 +69,10 @@  discard block
 block discarded – undo
69 69
     public function has(string $name): bool
70 70
     {
71 71
         if ($this->driverType == self::APCU_DRIVER) {
72
-            return apcu_exists($this->prefix . $name);
72
+            return apcu_exists($this->prefix.$name);
73 73
         }
74 74
 
75
-        return apc_exists($this->prefix . $name);
75
+        return apc_exists($this->prefix.$name);
76 76
     }
77 77
 
78 78
     /**
@@ -81,10 +81,10 @@  discard block
 block discarded – undo
81 81
     public function get(string $name)
82 82
     {
83 83
         if ($this->driverType == self::APCU_DRIVER) {
84
-            return apcu_fetch($this->prefix . $name);
84
+            return apcu_fetch($this->prefix.$name);
85 85
         }
86 86
 
87
-        return apc_fetch($this->prefix . $name);
87
+        return apc_fetch($this->prefix.$name);
88 88
     }
89 89
 
90 90
     /**
@@ -93,10 +93,10 @@  discard block
 block discarded – undo
93 93
     public function set(string $name, $data, $ttl = null)
94 94
     {
95 95
         if ($this->driverType == self::APCU_DRIVER) {
96
-            return apcu_store($this->prefix . $name, $data, $this->lifetime($ttl, 0));
96
+            return apcu_store($this->prefix.$name, $data, $this->lifetime($ttl, 0));
97 97
         }
98 98
 
99
-        return apc_store($this->prefix . $name, $data, $this->lifetime($ttl, 0));
99
+        return apc_store($this->prefix.$name, $data, $this->lifetime($ttl, 0));
100 100
     }
101 101
 
102 102
     /**
@@ -105,12 +105,12 @@  discard block
 block discarded – undo
105 105
     public function delete(string $name)
106 106
     {
107 107
         if ($this->driverType == self::APCU_DRIVER) {
108
-            apcu_delete($this->prefix . $name);
108
+            apcu_delete($this->prefix.$name);
109 109
 
110 110
             return;
111 111
         }
112 112
 
113
-        apc_delete($this->prefix . $name);
113
+        apc_delete($this->prefix.$name);
114 114
     }
115 115
 
116 116
     /**
@@ -119,10 +119,10 @@  discard block
 block discarded – undo
119 119
     public function inc(string $name, int $delta = 1): int
120 120
     {
121 121
         if ($this->driverType == self::APCU_DRIVER) {
122
-            return apcu_inc($this->prefix . $name, $delta);
122
+            return apcu_inc($this->prefix.$name, $delta);
123 123
         }
124 124
 
125
-        return apc_inc($this->prefix . $name, $delta);
125
+        return apc_inc($this->prefix.$name, $delta);
126 126
     }
127 127
 
128 128
     /**
@@ -131,10 +131,10 @@  discard block
 block discarded – undo
131 131
     public function dec(string $name, int $delta = 1): int
132 132
     {
133 133
         if ($this->driverType == self::APCU_DRIVER) {
134
-            return apcu_dec($this->prefix . $name, $delta);
134
+            return apcu_dec($this->prefix.$name, $delta);
135 135
         }
136 136
 
137
-        return apc_dec($this->prefix . $name, $delta);
137
+        return apc_dec($this->prefix.$name, $delta);
138 138
     }
139 139
 
140 140
     /**
Please login to merge, or discard this patch.
source/Spiral/Cache/Stores/XCacheStore.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
      */
42 42
     public function has(string $name): bool
43 43
     {
44
-        return xcache_isset($this->prefix . $name);
44
+        return xcache_isset($this->prefix.$name);
45 45
     }
46 46
 
47 47
     /**
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
      */
50 50
     public function get(string $name)
51 51
     {
52
-        return xcache_get($this->prefix . $name);
52
+        return xcache_get($this->prefix.$name);
53 53
     }
54 54
 
55 55
     /**
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
      */
58 58
     public function set(string $name, $data, $ttl = null)
59 59
     {
60
-        return xcache_set($this->prefix . $name, $data, $this->lifetime($ttl, 0));
60
+        return xcache_set($this->prefix.$name, $data, $this->lifetime($ttl, 0));
61 61
     }
62 62
 
63 63
     /**
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
      */
66 66
     public function delete(string $name)
67 67
     {
68
-        xcache_unset($this->prefix . $name);
68
+        xcache_unset($this->prefix.$name);
69 69
     }
70 70
 
71 71
     /**
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
      */
74 74
     public function inc(string $name, int $delta = 1): int
75 75
     {
76
-        return xcache_inc($this->prefix . $name, $delta);
76
+        return xcache_inc($this->prefix.$name, $delta);
77 77
     }
78 78
 
79 79
     /**
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
      */
82 82
     public function dec(string $name, int $delta = 1): int
83 83
     {
84
-        return xcache_dec($this->prefix . $name, $delta);
84
+        return xcache_dec($this->prefix.$name, $delta);
85 85
     }
86 86
 
87 87
     /**
Please login to merge, or discard this patch.
source/Spiral/ORM/Helpers/ColumnRenderer.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -86,7 +86,7 @@
 block discarded – undo
86 86
      * @param bool           $hasDefault Must be set to true if default value was set by user.
87 87
      * @param mixed          $default    Default value declared by record schema.
88 88
      *
89
-     * @return mixed
89
+     * @return AbstractColumn
90 90
      *
91 91
      * @throws DefinitionException
92 92
      * @throws \Spiral\Database\Exceptions\SchemaException
Please login to merge, or discard this patch.
source/Spiral/Database/Schemas/Prototypes/AbstractColumn.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -613,7 +613,7 @@  discard block
 block discarded – undo
613 613
      */
614 614
     public function __toString()
615 615
     {
616
-        return $this->table . '.' . $this->getName();
616
+        return $this->table.'.'.$this->getName();
617 617
     }
618 618
 
619 619
     /**
@@ -671,7 +671,7 @@  discard block
 block discarded – undo
671 671
         }
672 672
 
673 673
         if (!empty($enumValues)) {
674
-            return '(' . implode(', ', $enumValues) . ')';
674
+            return '('.implode(', ', $enumValues).')';
675 675
         }
676 676
 
677 677
         return '';
@@ -740,7 +740,7 @@  discard block
 block discarded – undo
740 740
                 $timestamp = strtotime($value);
741 741
                 if ($timestamp === false) {
742 742
                     throw new DefaultValueException(
743
-                        "Unable to normalize timestamp '{$value}' for column type '{$type}' in " . get_class($this)
743
+                        "Unable to normalize timestamp '{$value}' for column type '{$type}' in ".get_class($this)
744 744
                     );
745 745
                 }
746 746
 
Please login to merge, or discard this patch.
source/Spiral/ORM/Schemas/SchemaBuilder.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -288,8 +288,8 @@  discard block
 block discarded – undo
288 288
         bool $unique = true,
289 289
         bool $resetState = false
290 290
     ): AbstractTable {
291
-        if (isset($this->tables[$database . '.table'])) {
292
-            $schema = $this->tables[$database . '.table'];
291
+        if (isset($this->tables[$database.'.table'])) {
292
+            $schema = $this->tables[$database.'.table'];
293 293
 
294 294
             if ($unique) {
295 295
                 throw new DoubleReferenceException(
@@ -299,7 +299,7 @@  discard block
 block discarded – undo
299 299
         } else {
300 300
             //Requesting thought DatabaseManager
301 301
             $schema = $this->manager->database($database)->table($table)->getSchema();
302
-            $this->tables[$database . '.' . $table] = $schema;
302
+            $this->tables[$database.'.'.$table] = $schema;
303 303
         }
304 304
 
305 305
         $schema = clone $schema;
@@ -320,7 +320,7 @@  discard block
 block discarded – undo
320 320
      */
321 321
     protected function pushTable(AbstractTable $table, string $database = null)
322 322
     {
323
-        $this->tables[$database . '.' . $table->getName()] = $table;
323
+        $this->tables[$database.'.'.$table->getName()] = $table;
324 324
 
325 325
     }
326 326
 }
327 327
\ No newline at end of file
Please login to merge, or discard this patch.
source/Spiral/ORM/Record.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -136,8 +136,8 @@
 block discarded – undo
136 136
      *
137 137
      * @see Record::$indexes
138 138
      */
139
-    const INDEX  = 1000;            //Default index type
140
-    const UNIQUE = 2000;            //Unique index definition
139
+    const INDEX  = 1000; //Default index type
140
+    const UNIQUE = 2000; //Unique index definition
141 141
 
142 142
     /**
143 143
      * Errors in relations and acessors.
Please login to merge, or discard this patch.