@@ -1,6 +1,6 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -declare(strict_types=1); |
|
| 3 | +declare(strict_types = 1); |
|
| 4 | 4 | |
| 5 | 5 | namespace Teebot\Command\Listener; |
| 6 | 6 | |
@@ -9,7 +9,7 @@ discard block |
||
| 9 | 9 | * @author Stanislav Drozdov <[email protected]> |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -declare(strict_types=1); |
|
| 12 | +declare(strict_types = 1); |
|
| 13 | 13 | |
| 14 | 14 | namespace Teebot\Api\Command; |
| 15 | 15 | |
@@ -274,7 +274,7 @@ discard block |
||
| 274 | 274 | * |
| 275 | 275 | * @return bool |
| 276 | 276 | */ |
| 277 | - protected function isCommandSupported(?string $preDefinedCommand, string $command): bool |
|
| 277 | + protected function isCommandSupported(?string $preDefinedCommand, string $command) : bool |
|
| 278 | 278 | { |
| 279 | 279 | return $preDefinedCommand !== null && strtolower($preDefinedCommand) == strtolower($command); |
| 280 | 280 | } |
@@ -48,8 +48,8 @@ discard block |
||
| 48 | 48 | protected $httpClient; |
| 49 | 49 | |
| 50 | 50 | /** |
| 51 | - * @param ContainerInterface $config |
|
| 52 | - * @param HttpClient $httpClient |
|
| 51 | + * @param \Teebot\Configuration\ContainerInterface $config |
|
| 52 | + * @param \Teebot\Api\HttpClient $httpClient |
|
| 53 | 53 | */ |
| 54 | 54 | public function __construct(ContainerInterface $config, HttpClient $httpClient) |
| 55 | 55 | { |
@@ -60,7 +60,7 @@ discard block |
||
| 60 | 60 | /** |
| 61 | 61 | * Returns configuration container |
| 62 | 62 | * |
| 63 | - * @return ContainerInterface |
|
| 63 | + * @return \Teebot\Configuration\ContainerInterface |
|
| 64 | 64 | */ |
| 65 | 65 | public function getConfig(): ContainerInterface |
| 66 | 66 | { |
@@ -104,7 +104,7 @@ discard block |
||
| 104 | 104 | * - Inline Query |
| 105 | 105 | * - Chosen Inline Result |
| 106 | 106 | * |
| 107 | - * @param EntityInterface $entity Update or Error entity object |
|
| 107 | + * @param \Teebot\Api\Entity\EntityInterface $entity Update or Error entity object |
|
| 108 | 108 | * |
| 109 | 109 | * @return array |
| 110 | 110 | */ |
@@ -173,7 +173,7 @@ discard block |
||
| 173 | 173 | * will not be triggered otherwise process will continue until either first false returned or the very |
| 174 | 174 | * last event in the flow. |
| 175 | 175 | * |
| 176 | - * @param ChainItem $chainItem |
|
| 176 | + * @param ValueObject\ChainItem $chainItem |
|
| 177 | 177 | * |
| 178 | 178 | * @return bool |
| 179 | 179 | */ |
@@ -216,7 +216,7 @@ discard block |
||
| 216 | 216 | /** |
| 217 | 217 | * Returns event configuration item search by the data from entity |
| 218 | 218 | * |
| 219 | - * @param EntityInterface $entity Entity for which the corresponding event should be triggered |
|
| 219 | + * @param \Teebot\Api\Entity\EntityInterface $entity Entity for which the corresponding event should be triggered |
|
| 220 | 220 | * be treated as a command |
| 221 | 221 | * |
| 222 | 222 | * @return null|EventConfig |
@@ -277,9 +277,9 @@ discard block |
||
| 277 | 277 | * @param MethodInterface $method Method instance |
| 278 | 278 | * @param bool $silentMode If set to true then the events, mapped (in config or by default) |
| 279 | 279 | * to the entities in the result will not be triggered |
| 280 | - * @param EntityInterface $parent Parent entity (if any) |
|
| 280 | + * @param \Teebot\Api\Entity\EntityInterface $parent Parent entity (if any) |
|
| 281 | 281 | * |
| 282 | - * @return Response |
|
| 282 | + * @return \Teebot\Api\Response |
|
| 283 | 283 | */ |
| 284 | 284 | public function call(MethodInterface $method, $silentMode = false, EntityInterface $parent = null) |
| 285 | 285 | { |
@@ -297,7 +297,7 @@ discard block |
||
| 297 | 297 | * @param bool $silentMode If set to true then the events, mapped (in config or by default) |
| 298 | 298 | * to the entities in the result will not be triggered |
| 299 | 299 | * |
| 300 | - * @return Response |
|
| 300 | + * @return \Teebot\Api\Response |
|
| 301 | 301 | */ |
| 302 | 302 | public function getWebhookResponse($data, $silentMode = false) |
| 303 | 303 | { |
@@ -309,11 +309,11 @@ discard block |
||
| 309 | 309 | /** |
| 310 | 310 | * Processes entities from the response object if not in silent mode or error is received. |
| 311 | 311 | * |
| 312 | - * @param Response $response Response object which includes entities |
|
| 312 | + * @param \Teebot\Api\Response $response Response object which includes entities |
|
| 313 | 313 | * @param bool $silentMode If set to true then the events, mapped (in config or by default) |
| 314 | 314 | * to the entities in the result will not be triggered |
| 315 | 315 | * |
| 316 | - * @return Response |
|
| 316 | + * @return \Teebot\Api\Response |
|
| 317 | 317 | */ |
| 318 | 318 | protected function processResponse(Response $response, $silentMode = false) |
| 319 | 319 | { |
@@ -10,7 +10,7 @@ |
||
| 10 | 10 | * @author Stanislav Drozdov <[email protected]> |
| 11 | 11 | */ |
| 12 | 12 | |
| 13 | -declare(strict_types=1); |
|
| 13 | +declare(strict_types = 1); |
|
| 14 | 14 | |
| 15 | 15 | namespace Teebot\Api\Command; |
| 16 | 16 | |
@@ -1,6 +1,6 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -declare(strict_types=1); |
|
| 3 | +declare(strict_types = 1); |
|
| 4 | 4 | |
| 5 | 5 | namespace Teebot\Api; |
| 6 | 6 | |
@@ -1,6 +1,6 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -declare(strict_types=1); |
|
| 3 | +declare(strict_types = 1); |
|
| 4 | 4 | |
| 5 | 5 | namespace Teebot\Api\Logger; |
| 6 | 6 | |
@@ -29,7 +29,7 @@ discard block |
||
| 29 | 29 | public function __construct(ContainerInterface $config) |
| 30 | 30 | { |
| 31 | 31 | $this->config = $config; |
| 32 | - $filename = TEEBOT_ROOT . $this->config->get('logger.filename'); |
|
| 32 | + $filename = TEEBOT_ROOT.$this->config->get('logger.filename'); |
|
| 33 | 33 | $this->logger = new Monolog('Teebot'); |
| 34 | 34 | $this->logger->pushHandler( |
| 35 | 35 | new StreamHandler($filename, Monolog::WARNING) |
@@ -8,7 +8,7 @@ discard block |
||
| 8 | 8 | * @author Stanislav Drozdov <[email protected]> |
| 9 | 9 | */ |
| 10 | 10 | |
| 11 | -declare(strict_types=1); |
|
| 11 | +declare(strict_types = 1); |
|
| 12 | 12 | |
| 13 | 13 | namespace Teebot\Api\Traits; |
| 14 | 14 | |
@@ -26,7 +26,7 @@ discard block |
||
| 26 | 26 | */ |
| 27 | 27 | protected function getSetGetMethodName(string $prefix, string $name): ?string |
| 28 | 28 | { |
| 29 | - $setter = $prefix . str_replace("_", "", ucwords($name, "_")); |
|
| 29 | + $setter = $prefix.str_replace("_", "", ucwords($name, "_")); |
|
| 30 | 30 | |
| 31 | 31 | if (method_exists($this, $setter)) { |
| 32 | 32 | return $setter; |
@@ -8,7 +8,7 @@ |
||
| 8 | 8 | * @author Stanislav Drozdov <[email protected]> |
| 9 | 9 | */ |
| 10 | 10 | |
| 11 | -declare(strict_types=1); |
|
| 11 | +declare(strict_types = 1); |
|
| 12 | 12 | |
| 13 | 13 | namespace Teebot\Api\Traits; |
| 14 | 14 | |
@@ -1,6 +1,6 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -declare(strict_types=1); |
|
| 3 | +declare(strict_types = 1); |
|
| 4 | 4 | |
| 5 | 5 | namespace Teebot\Configuration; |
| 6 | 6 | |
@@ -1,6 +1,6 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -declare(strict_types=1); |
|
| 3 | +declare(strict_types = 1); |
|
| 4 | 4 | |
| 5 | 5 | namespace Teebot\Configuration\ValueObject; |
| 6 | 6 | |