@@ -38,7 +38,7 @@ discard block |
||
38 | 38 | |
39 | 39 | public function __construct(ConfigContainer $config) |
40 | 40 | { |
41 | - define('TEEBOT_ROOT', realpath(__DIR__ . '/../')); |
|
41 | + define('TEEBOT_ROOT', realpath(__DIR__.'/../')); |
|
42 | 42 | |
43 | 43 | $this->init($config); |
44 | 44 | } |
@@ -97,7 +97,7 @@ discard block |
||
97 | 97 | if ($response instanceof Response) { |
98 | 98 | $offset = $response->getOffset(); |
99 | 99 | } |
100 | - } catch (\Exception $e){ |
|
100 | + } catch (\Exception $e) { |
|
101 | 101 | $this->logger->exception($e); |
102 | 102 | } |
103 | 103 |
@@ -142,7 +142,7 @@ |
||
142 | 142 | $entity = null; |
143 | 143 | |
144 | 144 | if (!class_exists($entityClass)) { |
145 | - throw new BuildEntityException('Entity "' . $entityClass . '" does not exists or not supported yet!'); |
|
145 | + throw new BuildEntityException('Entity "'.$entityClass.'" does not exists or not supported yet!'); |
|
146 | 146 | } |
147 | 147 | |
148 | 148 | /** @var AbstractEntity $entity */ |
@@ -21,7 +21,7 @@ |
||
21 | 21 | public function __construct(ConfigContainer $config) |
22 | 22 | { |
23 | 23 | $this->config = $config; |
24 | - $filename = TEEBOT_ROOT . $this->config->get('logger.filename'); |
|
24 | + $filename = TEEBOT_ROOT.$this->config->get('logger.filename'); |
|
25 | 25 | $this->logger = new Monolog('Teebot'); |
26 | 26 | $this->logger->pushHandler( |
27 | 27 | new StreamHandler($filename, Monolog::WARNING) |
@@ -25,7 +25,7 @@ |
||
25 | 25 | */ |
26 | 26 | protected function getSetGetMethodName($prefix, $name) |
27 | 27 | { |
28 | - $setter = $prefix . str_replace("_", "", ucwords($name, "_")); |
|
28 | + $setter = $prefix.str_replace("_", "", ucwords($name, "_")); |
|
29 | 29 | |
30 | 30 | if (method_exists($this, $setter)) { |
31 | 31 | return $setter; |
@@ -6,7 +6,7 @@ |
||
6 | 6 | |
7 | 7 | class MessageEntityArray extends AbstractEntity |
8 | 8 | { |
9 | - const ENTITY_TYPE = 'MessageEntityArray'; |
|
9 | + const ENTITY_TYPE = 'MessageEntityArray'; |
|
10 | 10 | |
11 | 11 | protected $entities; |
12 | 12 |
@@ -4,7 +4,7 @@ |
||
4 | 4 | |
5 | 5 | class UserProfilePhotos extends AbstractEntity |
6 | 6 | { |
7 | - const ENTITY_TYPE = 'UserProfilePhotos'; |
|
7 | + const ENTITY_TYPE = 'UserProfilePhotos'; |
|
8 | 8 | |
9 | 9 | protected $total_count; |
10 | 10 |
@@ -77,7 +77,7 @@ |
||
77 | 77 | public function download($storePath) |
78 | 78 | { |
79 | 79 | if (file_exists($storePath) && !is_writable($storePath)) { |
80 | - throw new EntityException('File "' . $storePath . '" is already exist!"'); |
|
80 | + throw new EntityException('File "'.$storePath.'" is already exist!"'); |
|
81 | 81 | } |
82 | 82 | |
83 | 83 | $filePath = $this->getFilePath(); |
@@ -20,7 +20,7 @@ |
||
20 | 20 | protected function initFileForUpload() |
21 | 21 | { |
22 | 22 | if (!$this->isFileReadable($this->file)) { |
23 | - throw new EntityException('File "' . $this->file . '" is not readable or does not exist!'); |
|
23 | + throw new EntityException('File "'.$this->file.'" is not readable or does not exist!'); |
|
24 | 24 | } |
25 | 25 | return fopen($this->file, 'r'); |
26 | 26 | } |
@@ -45,7 +45,7 @@ |
||
45 | 45 | $replace = []; |
46 | 46 | |
47 | 47 | foreach ($tokens as $token) { |
48 | - $envKey = static::ENV_PREFIX . strtoupper(substr($token, 1, strlen($token) - 2)); |
|
48 | + $envKey = static::ENV_PREFIX.strtoupper(substr($token, 1, strlen($token) - 2)); |
|
49 | 49 | $envValue = getenv($envKey); |
50 | 50 | |
51 | 51 | if ($envValue) { |