@@ -129,7 +129,7 @@ discard block |
||
| 129 | 129 | } |
| 130 | 130 | |
| 131 | 131 | if ($position == self::POSITION_IN_TAG) { |
| 132 | - $buffer = '<' . $buffer; |
|
| 132 | + $buffer = '<'.$buffer; |
|
| 133 | 133 | } |
| 134 | 134 | |
| 135 | 135 | //Handling previous token |
@@ -168,7 +168,7 @@ discard block |
||
| 168 | 168 | //Checking for invalid characters in tag name or arguments |
| 169 | 169 | if ($position == self::POSITION_IN_TAG) { |
| 170 | 170 | if (!preg_match('/[a-z0-9 \._\-="\':\/\r\n\t]/i', $char)) { |
| 171 | - $buffer = '<' . $buffer; |
|
| 171 | + $buffer = '<'.$buffer; |
|
| 172 | 172 | $position = self::POSITION_PLAIN_TEXT; |
| 173 | 173 | } |
| 174 | 174 | } |
@@ -202,18 +202,18 @@ discard block |
||
| 202 | 202 | continue; |
| 203 | 203 | } |
| 204 | 204 | |
| 205 | - $attributes[] = $attribute . '="' . $value . '"'; |
|
| 205 | + $attributes[] = $attribute.'="'.$value.'"'; |
|
| 206 | 206 | } |
| 207 | 207 | |
| 208 | 208 | if (!empty($attributes)) { |
| 209 | - $result .= ' ' . join(' ', $attributes); |
|
| 209 | + $result .= ' '.join(' ', $attributes); |
|
| 210 | 210 | } |
| 211 | 211 | |
| 212 | 212 | if ($token[HtmlTokenizer::TOKEN_TYPE] == HtmlTokenizer::TAG_SHORT) { |
| 213 | 213 | $result .= '/'; |
| 214 | 214 | } |
| 215 | 215 | |
| 216 | - return '<' . $result . '>'; |
|
| 216 | + return '<'.$result.'>'; |
|
| 217 | 217 | } |
| 218 | 218 | |
| 219 | 219 | /** |
@@ -227,7 +227,7 @@ discard block |
||
| 227 | 227 | $token = [ |
| 228 | 228 | self::TOKEN_NAME => '', |
| 229 | 229 | self::TOKEN_TYPE => self::TAG_OPEN, |
| 230 | - self::TOKEN_CONTENT => '<' . ($content = $this->repairPHP($content)) . '>', |
|
| 230 | + self::TOKEN_CONTENT => '<'.($content = $this->repairPHP($content)).'>', |
|
| 231 | 231 | self::TOKEN_ATTRIBUTES => [] |
| 232 | 232 | ]; |
| 233 | 233 | |
@@ -190,11 +190,11 @@ |
||
| 190 | 190 | protected function getPath(BucketInterface $bucket, $name) |
| 191 | 191 | { |
| 192 | 192 | if (empty($this->options['home'])) { |
| 193 | - return $this->files->normalizePath($bucket->getOption('directory') . $name); |
|
| 193 | + return $this->files->normalizePath($bucket->getOption('directory').$name); |
|
| 194 | 194 | } |
| 195 | 195 | |
| 196 | 196 | return $this->files->normalizePath( |
| 197 | - $this->options['home'] . '/' . $bucket->getOption('directory') . $name |
|
| 197 | + $this->options['home'].'/'.$bucket->getOption('directory').$name |
|
| 198 | 198 | ); |
| 199 | 199 | } |
| 200 | 200 | } |
| 201 | 201 | \ No newline at end of file |
@@ -218,7 +218,7 @@ discard block |
||
| 218 | 218 | protected function getPath(BucketInterface $bucket, $name) |
| 219 | 219 | { |
| 220 | 220 | return $this->files->normalizePath( |
| 221 | - $this->options['home'] . '/' . $bucket->getOption('directory') . '/' . $name |
|
| 221 | + $this->options['home'].'/'.$bucket->getOption('directory').'/'.$name |
|
| 222 | 222 | ); |
| 223 | 223 | } |
| 224 | 224 | |
@@ -232,7 +232,7 @@ discard block |
||
| 232 | 232 | */ |
| 233 | 233 | protected function getUri(BucketInterface $bucket, $name) |
| 234 | 234 | { |
| 235 | - return 'ssh2.sftp://' . $this->sftp . $this->getPath($bucket, $name); |
|
| 235 | + return 'ssh2.sftp://'.$this->sftp.$this->getPath($bucket, $name); |
|
| 236 | 236 | } |
| 237 | 237 | |
| 238 | 238 | /** |
@@ -248,7 +248,7 @@ discard block |
||
| 248 | 248 | $directory = dirname($this->getPath($bucket, $name)); |
| 249 | 249 | |
| 250 | 250 | $mode = $bucket->getOption('mode', FilesInterface::RUNTIME); |
| 251 | - if (file_exists('ssh2.sftp://' . $this->sftp . $directory)) { |
|
| 251 | + if (file_exists('ssh2.sftp://'.$this->sftp.$directory)) { |
|
| 252 | 252 | if (function_exists('ssh2_sftp_chmod')) { |
| 253 | 253 | ssh2_sftp_chmod($this->sftp, $directory, $mode | 0111); |
| 254 | 254 | } |
@@ -264,9 +264,9 @@ discard block |
||
| 264 | 264 | continue; |
| 265 | 265 | } |
| 266 | 266 | |
| 267 | - $location .= '/' . $directory; |
|
| 267 | + $location .= '/'.$directory; |
|
| 268 | 268 | |
| 269 | - if (!file_exists('ssh2.sftp://' . $this->sftp . $location)) { |
|
| 269 | + if (!file_exists('ssh2.sftp://'.$this->sftp.$location)) { |
|
| 270 | 270 | if (!ssh2_sftp_mkdir($this->sftp, $location)) { |
| 271 | 271 | throw new ServerException( |
| 272 | 272 | "Unable to create directory {$location} using sftp connection." |
@@ -255,7 +255,7 @@ |
||
| 255 | 255 | protected function getPath(BucketInterface $bucket, $name) |
| 256 | 256 | { |
| 257 | 257 | return $this->files->normalizePath( |
| 258 | - $this->options['home'] . '/' . $bucket->getOption('directory') . $name |
|
| 258 | + $this->options['home'].'/'.$bucket->getOption('directory').$name |
|
| 259 | 259 | ); |
| 260 | 260 | } |
| 261 | 261 | |
@@ -140,7 +140,7 @@ |
||
| 140 | 140 | */ |
| 141 | 141 | public function buildAddress($name) |
| 142 | 142 | { |
| 143 | - return $this->prefix . $name; |
|
| 143 | + return $this->prefix.$name; |
|
| 144 | 144 | } |
| 145 | 145 | |
| 146 | 146 | /** |
@@ -90,7 +90,7 @@ discard block |
||
| 90 | 90 | */ |
| 91 | 91 | public function has($name) |
| 92 | 92 | { |
| 93 | - return $this->driver->get($this->prefix . $name); |
|
| 93 | + return $this->driver->get($this->prefix.$name); |
|
| 94 | 94 | } |
| 95 | 95 | |
| 96 | 96 | /** |
@@ -98,7 +98,7 @@ discard block |
||
| 98 | 98 | */ |
| 99 | 99 | public function get($name) |
| 100 | 100 | { |
| 101 | - return $this->driver->get($this->prefix . $name); |
|
| 101 | + return $this->driver->get($this->prefix.$name); |
|
| 102 | 102 | } |
| 103 | 103 | |
| 104 | 104 | /** |
@@ -113,7 +113,7 @@ discard block |
||
| 113 | 113 | $lifetime = 0; |
| 114 | 114 | } |
| 115 | 115 | |
| 116 | - return $this->driver->set($this->prefix . $name, $data, $lifetime); |
|
| 116 | + return $this->driver->set($this->prefix.$name, $data, $lifetime); |
|
| 117 | 117 | } |
| 118 | 118 | |
| 119 | 119 | /** |
@@ -121,7 +121,7 @@ discard block |
||
| 121 | 121 | */ |
| 122 | 122 | public function forever($name, $data) |
| 123 | 123 | { |
| 124 | - return $this->driver->forever($this->prefix . $name, $data); |
|
| 124 | + return $this->driver->forever($this->prefix.$name, $data); |
|
| 125 | 125 | } |
| 126 | 126 | |
| 127 | 127 | /** |
@@ -129,7 +129,7 @@ discard block |
||
| 129 | 129 | */ |
| 130 | 130 | public function delete($name) |
| 131 | 131 | { |
| 132 | - return $this->driver->delete($this->prefix . $name); |
|
| 132 | + return $this->driver->delete($this->prefix.$name); |
|
| 133 | 133 | } |
| 134 | 134 | |
| 135 | 135 | /** |
@@ -137,7 +137,7 @@ discard block |
||
| 137 | 137 | */ |
| 138 | 138 | public function inc($name, $delta = 1) |
| 139 | 139 | { |
| 140 | - return $this->driver->inc($this->prefix . $name); |
|
| 140 | + return $this->driver->inc($this->prefix.$name); |
|
| 141 | 141 | } |
| 142 | 142 | |
| 143 | 143 | /** |
@@ -145,7 +145,7 @@ discard block |
||
| 145 | 145 | */ |
| 146 | 146 | public function dec($name, $delta = 1) |
| 147 | 147 | { |
| 148 | - return $this->driver->dec($this->prefix . $name, $delta); |
|
| 148 | + return $this->driver->dec($this->prefix.$name, $delta); |
|
| 149 | 149 | } |
| 150 | 150 | |
| 151 | 151 | /** |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | */ |
| 41 | 41 | public function has($name) |
| 42 | 42 | { |
| 43 | - return xcache_isset($this->prefix . $name); |
|
| 43 | + return xcache_isset($this->prefix.$name); |
|
| 44 | 44 | } |
| 45 | 45 | |
| 46 | 46 | /** |
@@ -48,7 +48,7 @@ discard block |
||
| 48 | 48 | */ |
| 49 | 49 | public function get($name) |
| 50 | 50 | { |
| 51 | - return xcache_get($this->prefix . $name); |
|
| 51 | + return xcache_get($this->prefix.$name); |
|
| 52 | 52 | } |
| 53 | 53 | |
| 54 | 54 | /** |
@@ -56,7 +56,7 @@ discard block |
||
| 56 | 56 | */ |
| 57 | 57 | public function set($name, $data, $lifetime) |
| 58 | 58 | { |
| 59 | - return xcache_set($this->prefix . $name, $data, $lifetime); |
|
| 59 | + return xcache_set($this->prefix.$name, $data, $lifetime); |
|
| 60 | 60 | } |
| 61 | 61 | |
| 62 | 62 | /** |
@@ -64,7 +64,7 @@ discard block |
||
| 64 | 64 | */ |
| 65 | 65 | public function forever($name, $data) |
| 66 | 66 | { |
| 67 | - return xcache_set($this->prefix . $name, $data, 0); |
|
| 67 | + return xcache_set($this->prefix.$name, $data, 0); |
|
| 68 | 68 | } |
| 69 | 69 | |
| 70 | 70 | /** |
@@ -72,7 +72,7 @@ discard block |
||
| 72 | 72 | */ |
| 73 | 73 | public function delete($name) |
| 74 | 74 | { |
| 75 | - xcache_unset($this->prefix . $name); |
|
| 75 | + xcache_unset($this->prefix.$name); |
|
| 76 | 76 | } |
| 77 | 77 | |
| 78 | 78 | /** |
@@ -80,7 +80,7 @@ discard block |
||
| 80 | 80 | */ |
| 81 | 81 | public function inc($name, $delta = 1) |
| 82 | 82 | { |
| 83 | - return xcache_inc($this->prefix . $name, $delta); |
|
| 83 | + return xcache_inc($this->prefix.$name, $delta); |
|
| 84 | 84 | } |
| 85 | 85 | |
| 86 | 86 | /** |
@@ -88,7 +88,7 @@ discard block |
||
| 88 | 88 | */ |
| 89 | 89 | public function dec($name, $delta = 1) |
| 90 | 90 | { |
| 91 | - return xcache_dec($this->prefix . $name, $delta); |
|
| 91 | + return xcache_dec($this->prefix.$name, $delta); |
|
| 92 | 92 | } |
| 93 | 93 | |
| 94 | 94 | /** |
@@ -68,10 +68,10 @@ discard block |
||
| 68 | 68 | public function has($name) |
| 69 | 69 | { |
| 70 | 70 | if ($this->driver == self::APCU_DRIVER) { |
| 71 | - return apcu_exists($this->prefix . $name); |
|
| 71 | + return apcu_exists($this->prefix.$name); |
|
| 72 | 72 | } |
| 73 | 73 | |
| 74 | - return apc_exists($this->prefix . $name); |
|
| 74 | + return apc_exists($this->prefix.$name); |
|
| 75 | 75 | } |
| 76 | 76 | |
| 77 | 77 | /** |
@@ -80,10 +80,10 @@ discard block |
||
| 80 | 80 | public function get($name) |
| 81 | 81 | { |
| 82 | 82 | if ($this->driver == self::APCU_DRIVER) { |
| 83 | - return apcu_fetch($this->prefix . $name); |
|
| 83 | + return apcu_fetch($this->prefix.$name); |
|
| 84 | 84 | } |
| 85 | 85 | |
| 86 | - return apc_fetch($this->prefix . $name); |
|
| 86 | + return apc_fetch($this->prefix.$name); |
|
| 87 | 87 | } |
| 88 | 88 | |
| 89 | 89 | /** |
@@ -92,10 +92,10 @@ discard block |
||
| 92 | 92 | public function set($name, $data, $lifetime) |
| 93 | 93 | { |
| 94 | 94 | if ($this->driver == self::APCU_DRIVER) { |
| 95 | - return apcu_store($this->prefix . $name, $data, $lifetime); |
|
| 95 | + return apcu_store($this->prefix.$name, $data, $lifetime); |
|
| 96 | 96 | } |
| 97 | 97 | |
| 98 | - return apc_store($this->prefix . $name, $data, $lifetime); |
|
| 98 | + return apc_store($this->prefix.$name, $data, $lifetime); |
|
| 99 | 99 | } |
| 100 | 100 | |
| 101 | 101 | /** |
@@ -112,12 +112,12 @@ discard block |
||
| 112 | 112 | public function delete($name) |
| 113 | 113 | { |
| 114 | 114 | if ($this->driver == self::APCU_DRIVER) { |
| 115 | - apcu_delete($this->prefix . $name); |
|
| 115 | + apcu_delete($this->prefix.$name); |
|
| 116 | 116 | |
| 117 | 117 | return; |
| 118 | 118 | } |
| 119 | 119 | |
| 120 | - apc_delete($this->prefix . $name); |
|
| 120 | + apc_delete($this->prefix.$name); |
|
| 121 | 121 | } |
| 122 | 122 | |
| 123 | 123 | /** |
@@ -126,10 +126,10 @@ discard block |
||
| 126 | 126 | public function inc($name, $delta = 1) |
| 127 | 127 | { |
| 128 | 128 | if ($this->driver == self::APCU_DRIVER) { |
| 129 | - return apcu_inc($this->prefix . $name, $delta); |
|
| 129 | + return apcu_inc($this->prefix.$name, $delta); |
|
| 130 | 130 | } |
| 131 | 131 | |
| 132 | - return apc_inc($this->prefix . $name, $delta); |
|
| 132 | + return apc_inc($this->prefix.$name, $delta); |
|
| 133 | 133 | } |
| 134 | 134 | |
| 135 | 135 | /** |
@@ -138,10 +138,10 @@ discard block |
||
| 138 | 138 | public function dec($name, $delta = 1) |
| 139 | 139 | { |
| 140 | 140 | if ($this->driver == self::APCU_DRIVER) { |
| 141 | - return apcu_dec($this->prefix . $name, $delta); |
|
| 141 | + return apcu_dec($this->prefix.$name, $delta); |
|
| 142 | 142 | } |
| 143 | 143 | |
| 144 | - return apc_dec($this->prefix . $name, $delta); |
|
| 144 | + return apc_dec($this->prefix.$name, $delta); |
|
| 145 | 145 | } |
| 146 | 146 | |
| 147 | 147 | /** |
@@ -50,7 +50,7 @@ |
||
| 50 | 50 | && stripos($url, 'http://') === false && stripos($url, 'https://') === false |
| 51 | 51 | ) { |
| 52 | 52 | //Forcing scheme (not super great idea) |
| 53 | - $url = 'http://' . $url; |
|
| 53 | + $url = 'http://'.$url; |
|
| 54 | 54 | } |
| 55 | 55 | |
| 56 | 56 | return (bool)filter_var($url, FILTER_VALIDATE_URL); |