From 0ae5a53d86351c9165a296a5b38de019e185631b Mon Sep 17 00:00:00 2001 From: Alejandro Celaya Date: Tue, 20 Nov 2018 19:30:27 +0100 Subject: [PATCH] Enforced property types comments in one line --- .../CLI/src/Command/Api/DisableKeyCommand.php | 4 +-- .../src/Command/Api/GenerateKeyCommand.php | 4 +-- .../CLI/src/Command/Api/ListKeysCommand.php | 4 +-- .../ShortUrl/DeleteShortUrlCommand.php | 4 +-- .../ShortUrl/GeneratePreviewCommand.php | 8 ++--- .../ShortUrl/GenerateShortUrlCommand.php | 8 ++--- .../src/Command/ShortUrl/GetVisitsCommand.php | 4 +-- .../Command/ShortUrl/ListShortUrlsCommand.php | 8 ++--- .../Command/ShortUrl/ResolveUrlCommand.php | 4 +-- .../CLI/src/Command/Tag/CreateTagCommand.php | 4 +-- .../CLI/src/Command/Tag/DeleteTagsCommand.php | 4 +-- .../CLI/src/Command/Tag/ListTagsCommand.php | 4 +-- .../CLI/src/Command/Tag/RenameTagCommand.php | 4 +-- .../Command/Visit/ProcessVisitsCommand.php | 16 +++------- .../CLI/src/Command/Visit/UpdateDbCommand.php | 4 +-- .../Command/Api/DisableKeyCommandTest.php | 8 ++--- .../Command/Api/GenerateKeyCommandTest.php | 8 ++--- .../test/Command/Api/ListKeysCommandTest.php | 8 ++--- .../Config/GenerateCharsetCommandTest.php | 4 +-- .../ShortUrl/DeleteShortCodeCommandTest.php | 8 ++--- .../ShortUrl/GeneratePreviewCommandTest.php | 12 ++----- .../ShortUrl/GenerateShortUrlCommandTest.php | 8 ++--- .../Command/ShortUrl/GetVisitsCommandTest.php | 8 ++--- .../ShortUrl/ListShortUrlsCommandTest.php | 8 ++--- .../ShortUrl/ResolveUrlCommandTest.php | 8 ++--- .../test/Command/Tag/CreateTagCommandTest.php | 8 ++--- .../Command/Tag/DeleteTagsCommandTest.php | 12 ++----- .../test/Command/Tag/ListTagsCommandTest.php | 12 ++----- .../test/Command/Tag/RenameTagCommandTest.php | 12 ++----- .../Visit/ProcessVisitsCommandTest.php | 20 +++--------- .../Command/Visit/UpdateDbCommandTest.php | 8 ++--- module/CLI/test/ConfigProviderTest.php | 4 +-- .../test/Factory/ApplicationFactoryTest.php | 4 +-- .../Common/src/Collection/PathCollection.php | 4 +-- .../IpGeolocation/ChainIpLocationResolver.php | 4 +-- .../src/IpGeolocation/GeoLite2/DbUpdater.php | 12 ++----- .../GeoLite2LocationResolver.php | 4 +-- .../IpGeolocation/IpApiLocationResolver.php | 4 +-- .../src/Middleware/LocaleMiddleware.php | 4 +-- .../Adapter/PaginableRepositoryAdapter.php | 16 +++------- .../Common/src/Service/PreviewGenerator.php | 12 ++----- .../Extension/TranslatorExtension.php | 4 +-- module/Common/src/Util/DateRange.php | 8 ++--- module/Common/src/Util/IpAddress.php | 16 +++------- .../test-func/DbUnit/DatabaseTestCase.php | 4 +-- .../test/Collection/PathCollectionTest.php | 4 +-- module/Common/test/ConfigProviderTest.php | 4 +-- .../Common/test/Factory/CacheFactoryTest.php | 4 +-- .../DottedAccessConfigAbstractFactoryTest.php | 4 +-- ...seImplicitOptionsMiddlewareFactoryTest.php | 4 +-- .../test/Factory/EntityManagerFactoryTest.php | 4 +-- .../Common/test/Factory/LoggerFactoryTest.php | 4 +-- .../test/Factory/TranslatorFactoryTest.php | 4 +-- .../test/Image/ImageBuilderFactoryTest.php | 4 +-- module/Common/test/Image/ImageFactoryTest.php | 4 +-- .../ChainIpLocationResolverTest.php | 12 ++----- .../EmptyIpLocationResolverTest.php | 4 +-- .../IpGeolocation/GeoLite2/DbUpdaterTest.php | 16 +++------- .../GeoLite2LocationResolverTest.php | 8 ++--- .../IpApiLocationResolverTest.php | 8 ++--- .../ExceptionWithNewLineProcessorTest.php | 4 +-- .../test/Middleware/LocaleMiddlewareTest.php | 8 ++--- .../PaginableRepositoryAdapterTest.php | 8 ++--- .../test/Response/PixelResponseTest.php | 4 +-- .../test/Service/PreviewGeneratorTest.php | 12 ++----- .../Extension/TranslatorExtensionTest.php | 4 +-- .../test/Type/ChronosDateTimeTypeTest.php | 4 +-- .../src/Action/AbstractTrackingAction.php | 16 +++------- module/Core/src/Action/PreviewAction.php | 12 ++----- module/Core/src/Action/QrCodeAction.php | 12 ++----- module/Core/src/Action/RedirectAction.php | 4 +-- .../src/Exception/DeleteShortUrlException.php | 4 +-- .../src/Exception/ValidationException.php | 4 +-- .../src/Middleware/QrCodeCacheMiddleware.php | 4 +-- module/Core/src/Model/CreateShortUrlData.php | 12 ++----- module/Core/src/Model/ShortUrlMeta.php | 16 +++------- module/Core/src/Model/Visitor.php | 12 ++----- module/Core/src/Options/AppOptions.php | 16 +++------- .../src/Options/NotFoundShortUrlOptions.php | 8 ++--- module/Core/src/Response/NotFoundHandler.php | 8 ++--- .../ShortUrl/DeleteShortUrlService.php | 8 ++--- module/Core/src/Service/ShortUrlService.php | 4 +-- module/Core/src/Service/Tag/TagService.php | 4 +-- module/Core/src/Service/UrlShortener.php | 20 +++--------- module/Core/src/Service/VisitService.php | 4 +-- module/Core/src/Service/VisitsTracker.php | 4 +-- .../Transformer/ShortUrlDataTransformer.php | 4 +-- .../Repository/ShortUrlRepositoryTest.php | 4 +-- .../Repository/TagRepositoryTest.php | 4 +-- .../Repository/VisitRepositoryTest.php | 4 +-- module/Core/test/Action/PixelActionTest.php | 12 ++----- module/Core/test/Action/PreviewActionTest.php | 12 ++----- module/Core/test/Action/QrCodeActionTest.php | 8 ++--- .../Core/test/Action/RedirectActionTest.php | 16 +++------- module/Core/test/ConfigProviderTest.php | 4 +-- .../Middleware/QrCodeCacheMiddlewareTest.php | 8 ++--- .../test/Response/NotFoundHandlerTest.php | 8 ++--- .../ShortUrl/DeleteShortUrlServiceTest.php | 8 ++--- .../Core/test/Service/ShortUrlServiceTest.php | 8 ++--- .../Core/test/Service/Tag/TagServiceTest.php | 8 ++--- module/Core/test/Service/UrlShortenerTest.php | 16 +++------- module/Core/test/Service/VisitServiceTest.php | 8 ++--- .../Core/test/Service/VisitsTrackerTest.php | 8 ++--- .../Installer/src/Command/InstallCommand.php | 32 +++++-------------- .../Plugin/DatabaseConfigCustomizer.php | 4 +-- .../src/Model/CustomizableAppConfig.php | 20 +++--------- .../test/Command/InstallCommandTest.php | 16 +++------- .../ApplicationConfigCustomizerTest.php | 8 ++--- .../Plugin/DatabaseConfigCustomizerTest.php | 12 ++----- .../Plugin/LanguageConfigCustomizerTest.php | 8 ++--- .../UrlShortenerConfigCustomizerTest.php | 8 ++--- module/Installer/test/ConfigProviderTest.php | 4 +-- .../Factory/InstallApplicationFactoryTest.php | 4 +-- module/Rest/src/Action/AbstractRestAction.php | 4 +-- module/Rest/src/Action/AuthenticateAction.php | 8 ++--- .../ShortUrl/AbstractCreateShortUrlAction.php | 8 ++--- .../Action/ShortUrl/DeleteShortUrlAction.php | 4 +-- .../Action/ShortUrl/EditShortUrlAction.php | 4 +-- .../ShortUrl/EditShortUrlTagsAction.php | 4 +-- .../Action/ShortUrl/ListShortUrlsAction.php | 8 ++--- .../Action/ShortUrl/ResolveShortUrlAction.php | 8 ++--- .../SingleStepCreateShortUrlAction.php | 4 +-- .../Rest/src/Action/Tag/CreateTagsAction.php | 4 +-- .../Rest/src/Action/Tag/DeleteTagsAction.php | 4 +-- module/Rest/src/Action/Tag/ListTagsAction.php | 4 +-- .../Rest/src/Action/Tag/UpdateTagAction.php | 4 +-- .../Rest/src/Action/Visit/GetVisitsAction.php | 4 +-- module/Rest/src/Authentication/JWTService.php | 4 +-- .../Plugin/ApiKeyHeaderPlugin.php | 4 +-- .../Plugin/AuthorizationHeaderPlugin.php | 4 +-- .../RequestToHttpAuthPlugin.php | 4 +-- .../VerifyAuthenticationException.php | 8 ++--- .../Middleware/AuthenticationMiddleware.php | 12 ++----- module/Rest/src/Service/ApiKeyService.php | 4 +-- .../test/Action/AuthenticateActionTest.php | 12 ++----- .../ShortUrl/CreateShortUrlActionTest.php | 8 ++--- .../ShortUrl/DeleteShortUrlActionTest.php | 8 ++--- .../ShortUrl/EditShortUrlActionTest.php | 8 ++--- .../ShortUrl/EditShortUrlTagsActionTest.php | 8 ++--- .../ShortUrl/ListShortUrlsActionTest.php | 8 ++--- .../ShortUrl/ResolveShortUrlActionTest.php | 8 ++--- .../SingleStepCreateShortUrlActionTest.php | 12 ++----- .../test/Action/Tag/CreateTagsActionTest.php | 8 ++--- .../test/Action/Tag/DeleteTagsActionTest.php | 8 ++--- .../test/Action/Tag/ListTagsActionTest.php | 8 ++--- .../test/Action/Tag/UpdateTagActionTest.php | 8 ++--- .../test/Action/Visit/GetVisitsActionTest.php | 8 ++--- ...AuthenticationPluginManagerFactoryTest.php | 4 +-- .../test/Authentication/JWTServiceTest.php | 4 +-- .../Plugin/ApiKeyHeaderPluginTest.php | 8 ++--- .../Plugin/AuthorizationHeaderPluginTest.php | 8 ++--- .../RequestToAuthPluginTest.php | 8 ++--- module/Rest/test/ConfigProviderTest.php | 4 +-- .../JsonErrorResponseGeneratorTest.php | 4 +-- .../AuthenticationMiddlewareTest.php | 12 ++----- .../Middleware/BodyParserMiddlewareTest.php | 4 +-- .../Middleware/CrossDomainMiddlewareTest.php | 8 ++--- .../Middleware/PathVersionMiddlewareTest.php | 4 +-- ...ortUrlContentNegotiationMiddlewareTest.php | 8 ++--- .../Rest/test/Service/ApiKeyServiceTest.php | 8 ++--- phpcs.xml | 2 ++ 161 files changed, 303 insertions(+), 903 deletions(-) diff --git a/module/CLI/src/Command/Api/DisableKeyCommand.php b/module/CLI/src/Command/Api/DisableKeyCommand.php index 5d865fb7..e8472d4c 100644 --- a/module/CLI/src/Command/Api/DisableKeyCommand.php +++ b/module/CLI/src/Command/Api/DisableKeyCommand.php @@ -16,9 +16,7 @@ class DisableKeyCommand extends Command { public const NAME = 'api-key:disable'; - /** - * @var ApiKeyServiceInterface - */ + /** @var ApiKeyServiceInterface */ private $apiKeyService; public function __construct(ApiKeyServiceInterface $apiKeyService) diff --git a/module/CLI/src/Command/Api/GenerateKeyCommand.php b/module/CLI/src/Command/Api/GenerateKeyCommand.php index 8a958cbb..62aeb657 100644 --- a/module/CLI/src/Command/Api/GenerateKeyCommand.php +++ b/module/CLI/src/Command/Api/GenerateKeyCommand.php @@ -16,9 +16,7 @@ class GenerateKeyCommand extends Command { public const NAME = 'api-key:generate'; - /** - * @var ApiKeyServiceInterface - */ + /** @var ApiKeyServiceInterface */ private $apiKeyService; public function __construct(ApiKeyServiceInterface $apiKeyService) diff --git a/module/CLI/src/Command/Api/ListKeysCommand.php b/module/CLI/src/Command/Api/ListKeysCommand.php index 720b8d2b..3eb96e96 100644 --- a/module/CLI/src/Command/Api/ListKeysCommand.php +++ b/module/CLI/src/Command/Api/ListKeysCommand.php @@ -22,9 +22,7 @@ class ListKeysCommand extends Command public const NAME = 'api-key:list'; - /** - * @var ApiKeyServiceInterface - */ + /** @var ApiKeyServiceInterface */ private $apiKeyService; public function __construct(ApiKeyServiceInterface $apiKeyService) diff --git a/module/CLI/src/Command/ShortUrl/DeleteShortUrlCommand.php b/module/CLI/src/Command/ShortUrl/DeleteShortUrlCommand.php index 018130a1..2d6d563f 100644 --- a/module/CLI/src/Command/ShortUrl/DeleteShortUrlCommand.php +++ b/module/CLI/src/Command/ShortUrl/DeleteShortUrlCommand.php @@ -18,9 +18,7 @@ class DeleteShortUrlCommand extends Command public const NAME = 'short-url:delete'; private const ALIASES = ['short-code:delete']; - /** - * @var DeleteShortUrlServiceInterface - */ + /** @var DeleteShortUrlServiceInterface */ private $deleteShortUrlService; public function __construct(DeleteShortUrlServiceInterface $deleteShortUrlService) diff --git a/module/CLI/src/Command/ShortUrl/GeneratePreviewCommand.php b/module/CLI/src/Command/ShortUrl/GeneratePreviewCommand.php index 38cb6ade..8d600010 100644 --- a/module/CLI/src/Command/ShortUrl/GeneratePreviewCommand.php +++ b/module/CLI/src/Command/ShortUrl/GeneratePreviewCommand.php @@ -17,13 +17,9 @@ class GeneratePreviewCommand extends Command public const NAME = 'short-url:process-previews'; private const ALIASES = ['shortcode:process-previews', 'short-code:process-previews']; - /** - * @var PreviewGeneratorInterface - */ + /** @var PreviewGeneratorInterface */ private $previewGenerator; - /** - * @var ShortUrlServiceInterface - */ + /** @var ShortUrlServiceInterface */ private $shortUrlService; public function __construct(ShortUrlServiceInterface $shortUrlService, PreviewGeneratorInterface $previewGenerator) diff --git a/module/CLI/src/Command/ShortUrl/GenerateShortUrlCommand.php b/module/CLI/src/Command/ShortUrl/GenerateShortUrlCommand.php index 43f5d046..65b417ac 100644 --- a/module/CLI/src/Command/ShortUrl/GenerateShortUrlCommand.php +++ b/module/CLI/src/Command/ShortUrl/GenerateShortUrlCommand.php @@ -26,13 +26,9 @@ class GenerateShortUrlCommand extends Command public const NAME = 'short-url:generate'; private const ALIASES = ['shortcode:generate', 'short-code:generate']; - /** - * @var UrlShortenerInterface - */ + /** @var UrlShortenerInterface */ private $urlShortener; - /** - * @var array - */ + /** @var array */ private $domainConfig; public function __construct(UrlShortenerInterface $urlShortener, array $domainConfig) diff --git a/module/CLI/src/Command/ShortUrl/GetVisitsCommand.php b/module/CLI/src/Command/ShortUrl/GetVisitsCommand.php index ecedd707..467a76fa 100644 --- a/module/CLI/src/Command/ShortUrl/GetVisitsCommand.php +++ b/module/CLI/src/Command/ShortUrl/GetVisitsCommand.php @@ -21,9 +21,7 @@ class GetVisitsCommand extends Command public const NAME = 'short-url:visits'; private const ALIASES = ['shortcode:visits', 'short-code:visits']; - /** - * @var VisitsTrackerInterface - */ + /** @var VisitsTrackerInterface */ private $visitsTracker; public function __construct(VisitsTrackerInterface $visitsTracker) diff --git a/module/CLI/src/Command/ShortUrl/ListShortUrlsCommand.php b/module/CLI/src/Command/ShortUrl/ListShortUrlsCommand.php index 2be854b4..2bef076d 100644 --- a/module/CLI/src/Command/ShortUrl/ListShortUrlsCommand.php +++ b/module/CLI/src/Command/ShortUrl/ListShortUrlsCommand.php @@ -25,13 +25,9 @@ class ListShortUrlsCommand extends Command public const NAME = 'short-url:list'; private const ALIASES = ['shortcode:list', 'short-code:list']; - /** - * @var ShortUrlServiceInterface - */ + /** @var ShortUrlServiceInterface */ private $shortUrlService; - /** - * @var array - */ + /** @var array */ private $domainConfig; public function __construct(ShortUrlServiceInterface $shortUrlService, array $domainConfig) diff --git a/module/CLI/src/Command/ShortUrl/ResolveUrlCommand.php b/module/CLI/src/Command/ShortUrl/ResolveUrlCommand.php index 02dc1840..ca921ff4 100644 --- a/module/CLI/src/Command/ShortUrl/ResolveUrlCommand.php +++ b/module/CLI/src/Command/ShortUrl/ResolveUrlCommand.php @@ -18,9 +18,7 @@ class ResolveUrlCommand extends Command public const NAME = 'short-url:parse'; private const ALIASES = ['shortcode:parse', 'short-code:parse']; - /** - * @var UrlShortenerInterface - */ + /** @var UrlShortenerInterface */ private $urlShortener; public function __construct(UrlShortenerInterface $urlShortener) diff --git a/module/CLI/src/Command/Tag/CreateTagCommand.php b/module/CLI/src/Command/Tag/CreateTagCommand.php index 56a31239..b15746a5 100644 --- a/module/CLI/src/Command/Tag/CreateTagCommand.php +++ b/module/CLI/src/Command/Tag/CreateTagCommand.php @@ -14,9 +14,7 @@ class CreateTagCommand extends Command { public const NAME = 'tag:create'; - /** - * @var TagServiceInterface - */ + /** @var TagServiceInterface */ private $tagService; public function __construct(TagServiceInterface $tagService) diff --git a/module/CLI/src/Command/Tag/DeleteTagsCommand.php b/module/CLI/src/Command/Tag/DeleteTagsCommand.php index e2d3d27d..caac09bc 100644 --- a/module/CLI/src/Command/Tag/DeleteTagsCommand.php +++ b/module/CLI/src/Command/Tag/DeleteTagsCommand.php @@ -14,9 +14,7 @@ class DeleteTagsCommand extends Command { public const NAME = 'tag:delete'; - /** - * @var TagServiceInterface - */ + /** @var TagServiceInterface */ private $tagService; public function __construct(TagServiceInterface $tagService) diff --git a/module/CLI/src/Command/Tag/ListTagsCommand.php b/module/CLI/src/Command/Tag/ListTagsCommand.php index dd318f63..f0aa66f8 100644 --- a/module/CLI/src/Command/Tag/ListTagsCommand.php +++ b/module/CLI/src/Command/Tag/ListTagsCommand.php @@ -15,9 +15,7 @@ class ListTagsCommand extends Command { public const NAME = 'tag:list'; - /** - * @var TagServiceInterface - */ + /** @var TagServiceInterface */ private $tagService; public function __construct(TagServiceInterface $tagService) diff --git a/module/CLI/src/Command/Tag/RenameTagCommand.php b/module/CLI/src/Command/Tag/RenameTagCommand.php index a65ac04b..d942cd98 100644 --- a/module/CLI/src/Command/Tag/RenameTagCommand.php +++ b/module/CLI/src/Command/Tag/RenameTagCommand.php @@ -16,9 +16,7 @@ class RenameTagCommand extends Command { public const NAME = 'tag:rename'; - /** - * @var TagServiceInterface - */ + /** @var TagServiceInterface */ private $tagService; public function __construct(TagServiceInterface $tagService) diff --git a/module/CLI/src/Command/Visit/ProcessVisitsCommand.php b/module/CLI/src/Command/Visit/ProcessVisitsCommand.php index d1c76a4a..cc1e2687 100644 --- a/module/CLI/src/Command/Visit/ProcessVisitsCommand.php +++ b/module/CLI/src/Command/Visit/ProcessVisitsCommand.php @@ -21,21 +21,13 @@ class ProcessVisitsCommand extends Command { public const NAME = 'visit:process'; - /** - * @var VisitServiceInterface - */ + /** @var VisitServiceInterface */ private $visitService; - /** - * @var IpLocationResolverInterface - */ + /** @var IpLocationResolverInterface */ private $ipLocationResolver; - /** - * @var Locker - */ + /** @var Locker */ private $locker; - /** - * @var OutputInterface - */ + /** @var OutputInterface */ private $output; public function __construct( diff --git a/module/CLI/src/Command/Visit/UpdateDbCommand.php b/module/CLI/src/Command/Visit/UpdateDbCommand.php index cb228300..87eb6022 100644 --- a/module/CLI/src/Command/Visit/UpdateDbCommand.php +++ b/module/CLI/src/Command/Visit/UpdateDbCommand.php @@ -15,9 +15,7 @@ class UpdateDbCommand extends Command { public const NAME = 'visit:update-db'; - /** - * @var DbUpdaterInterface - */ + /** @var DbUpdaterInterface */ private $geoLiteDbUpdater; public function __construct(DbUpdaterInterface $geoLiteDbUpdater) diff --git a/module/CLI/test/Command/Api/DisableKeyCommandTest.php b/module/CLI/test/Command/Api/DisableKeyCommandTest.php index de214220..552e1060 100644 --- a/module/CLI/test/Command/Api/DisableKeyCommandTest.php +++ b/module/CLI/test/Command/Api/DisableKeyCommandTest.php @@ -13,13 +13,9 @@ use Symfony\Component\Console\Tester\CommandTester; class DisableKeyCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ protected $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $apiKeyService; public function setUp() diff --git a/module/CLI/test/Command/Api/GenerateKeyCommandTest.php b/module/CLI/test/Command/Api/GenerateKeyCommandTest.php index cfdb9130..73e4b4ae 100644 --- a/module/CLI/test/Command/Api/GenerateKeyCommandTest.php +++ b/module/CLI/test/Command/Api/GenerateKeyCommandTest.php @@ -15,13 +15,9 @@ use Symfony\Component\Console\Tester\CommandTester; class GenerateKeyCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ protected $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $apiKeyService; public function setUp() diff --git a/module/CLI/test/Command/Api/ListKeysCommandTest.php b/module/CLI/test/Command/Api/ListKeysCommandTest.php index 6a2ad8a3..b71b3a0a 100644 --- a/module/CLI/test/Command/Api/ListKeysCommandTest.php +++ b/module/CLI/test/Command/Api/ListKeysCommandTest.php @@ -13,13 +13,9 @@ use Symfony\Component\Console\Tester\CommandTester; class ListKeysCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ protected $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $apiKeyService; public function setUp() diff --git a/module/CLI/test/Command/Config/GenerateCharsetCommandTest.php b/module/CLI/test/Command/Config/GenerateCharsetCommandTest.php index b79dfe53..70ea2a71 100644 --- a/module/CLI/test/Command/Config/GenerateCharsetCommandTest.php +++ b/module/CLI/test/Command/Config/GenerateCharsetCommandTest.php @@ -13,9 +13,7 @@ use function str_split; class GenerateCharsetCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ protected $commandTester; public function setUp() diff --git a/module/CLI/test/Command/ShortUrl/DeleteShortCodeCommandTest.php b/module/CLI/test/Command/ShortUrl/DeleteShortCodeCommandTest.php index bab8c82c..f6fae5d1 100644 --- a/module/CLI/test/Command/ShortUrl/DeleteShortCodeCommandTest.php +++ b/module/CLI/test/Command/ShortUrl/DeleteShortCodeCommandTest.php @@ -16,13 +16,9 @@ use function sprintf; class DeleteShortCodeCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ private $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $service; public function setUp() diff --git a/module/CLI/test/Command/ShortUrl/GeneratePreviewCommandTest.php b/module/CLI/test/Command/ShortUrl/GeneratePreviewCommandTest.php index 183872ac..2a1dda39 100644 --- a/module/CLI/test/Command/ShortUrl/GeneratePreviewCommandTest.php +++ b/module/CLI/test/Command/ShortUrl/GeneratePreviewCommandTest.php @@ -20,17 +20,11 @@ use function substr_count; class GeneratePreviewCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ protected $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $previewGenerator; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $shortUrlService; public function setUp() diff --git a/module/CLI/test/Command/ShortUrl/GenerateShortUrlCommandTest.php b/module/CLI/test/Command/ShortUrl/GenerateShortUrlCommandTest.php index 2720fb45..9056aed7 100644 --- a/module/CLI/test/Command/ShortUrl/GenerateShortUrlCommandTest.php +++ b/module/CLI/test/Command/ShortUrl/GenerateShortUrlCommandTest.php @@ -17,13 +17,9 @@ use Symfony\Component\Console\Tester\CommandTester; class GenerateShortUrlCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ protected $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $urlShortener; public function setUp() diff --git a/module/CLI/test/Command/ShortUrl/GetVisitsCommandTest.php b/module/CLI/test/Command/ShortUrl/GetVisitsCommandTest.php index 1b839e15..bbca65ec 100644 --- a/module/CLI/test/Command/ShortUrl/GetVisitsCommandTest.php +++ b/module/CLI/test/Command/ShortUrl/GetVisitsCommandTest.php @@ -20,13 +20,9 @@ use function strpos; class GetVisitsCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ protected $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $visitsTracker; public function setUp() diff --git a/module/CLI/test/Command/ShortUrl/ListShortUrlsCommandTest.php b/module/CLI/test/Command/ShortUrl/ListShortUrlsCommandTest.php index 60710c31..c6800cc3 100644 --- a/module/CLI/test/Command/ShortUrl/ListShortUrlsCommandTest.php +++ b/module/CLI/test/Command/ShortUrl/ListShortUrlsCommandTest.php @@ -16,13 +16,9 @@ use Zend\Paginator\Paginator; class ListShortUrlsCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ protected $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $shortUrlService; public function setUp() diff --git a/module/CLI/test/Command/ShortUrl/ResolveUrlCommandTest.php b/module/CLI/test/Command/ShortUrl/ResolveUrlCommandTest.php index c05aced3..2cf9df88 100644 --- a/module/CLI/test/Command/ShortUrl/ResolveUrlCommandTest.php +++ b/module/CLI/test/Command/ShortUrl/ResolveUrlCommandTest.php @@ -16,13 +16,9 @@ use const PHP_EOL; class ResolveUrlCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ protected $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $urlShortener; public function setUp() diff --git a/module/CLI/test/Command/Tag/CreateTagCommandTest.php b/module/CLI/test/Command/Tag/CreateTagCommandTest.php index 55871da1..c7cf5949 100644 --- a/module/CLI/test/Command/Tag/CreateTagCommandTest.php +++ b/module/CLI/test/Command/Tag/CreateTagCommandTest.php @@ -14,13 +14,9 @@ use Symfony\Component\Console\Tester\CommandTester; class CreateTagCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ private $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $tagService; public function setUp() diff --git a/module/CLI/test/Command/Tag/DeleteTagsCommandTest.php b/module/CLI/test/Command/Tag/DeleteTagsCommandTest.php index 654431c5..31cc8e0e 100644 --- a/module/CLI/test/Command/Tag/DeleteTagsCommandTest.php +++ b/module/CLI/test/Command/Tag/DeleteTagsCommandTest.php @@ -13,17 +13,11 @@ use Symfony\Component\Console\Tester\CommandTester; class DeleteTagsCommandTest extends TestCase { - /** - * @var DeleteTagsCommand - */ + /** @var DeleteTagsCommand */ private $command; - /** - * @var CommandTester - */ + /** @var CommandTester */ private $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $tagService; public function setUp() diff --git a/module/CLI/test/Command/Tag/ListTagsCommandTest.php b/module/CLI/test/Command/Tag/ListTagsCommandTest.php index e21054ca..a1c64331 100644 --- a/module/CLI/test/Command/Tag/ListTagsCommandTest.php +++ b/module/CLI/test/Command/Tag/ListTagsCommandTest.php @@ -14,17 +14,11 @@ use Symfony\Component\Console\Tester\CommandTester; class ListTagsCommandTest extends TestCase { - /** - * @var ListTagsCommand - */ + /** @var ListTagsCommand */ private $command; - /** - * @var CommandTester - */ + /** @var CommandTester */ private $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $tagService; public function setUp() diff --git a/module/CLI/test/Command/Tag/RenameTagCommandTest.php b/module/CLI/test/Command/Tag/RenameTagCommandTest.php index 55cc2a24..b5e9b977 100644 --- a/module/CLI/test/Command/Tag/RenameTagCommandTest.php +++ b/module/CLI/test/Command/Tag/RenameTagCommandTest.php @@ -15,17 +15,11 @@ use Symfony\Component\Console\Tester\CommandTester; class RenameTagCommandTest extends TestCase { - /** - * @var RenameTagCommand - */ + /** @var RenameTagCommand */ private $command; - /** - * @var CommandTester - */ + /** @var CommandTester */ private $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $tagService; public function setUp() diff --git a/module/CLI/test/Command/Visit/ProcessVisitsCommandTest.php b/module/CLI/test/Command/Visit/ProcessVisitsCommandTest.php index fa653d0d..6db2af0b 100644 --- a/module/CLI/test/Command/Visit/ProcessVisitsCommandTest.php +++ b/module/CLI/test/Command/Visit/ProcessVisitsCommandTest.php @@ -26,25 +26,15 @@ use function sprintf; class ProcessVisitsCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ private $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $visitService; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $ipResolver; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $locker; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $lock; public function setUp() diff --git a/module/CLI/test/Command/Visit/UpdateDbCommandTest.php b/module/CLI/test/Command/Visit/UpdateDbCommandTest.php index 0857c64b..d6b6a494 100644 --- a/module/CLI/test/Command/Visit/UpdateDbCommandTest.php +++ b/module/CLI/test/Command/Visit/UpdateDbCommandTest.php @@ -14,13 +14,9 @@ use Symfony\Component\Console\Tester\CommandTester; class UpdateDbCommandTest extends TestCase { - /** - * @var CommandTester - */ + /** @var CommandTester */ private $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $dbUpdater; public function setUp() diff --git a/module/CLI/test/ConfigProviderTest.php b/module/CLI/test/ConfigProviderTest.php index 19a679ea..c222e8aa 100644 --- a/module/CLI/test/ConfigProviderTest.php +++ b/module/CLI/test/ConfigProviderTest.php @@ -8,9 +8,7 @@ use Shlinkio\Shlink\CLI\ConfigProvider; class ConfigProviderTest extends TestCase { - /** - * @var ConfigProvider - */ + /** @var ConfigProvider */ protected $configProvider; public function setUp() diff --git a/module/CLI/test/Factory/ApplicationFactoryTest.php b/module/CLI/test/Factory/ApplicationFactoryTest.php index 5c28e65f..f7d4db21 100644 --- a/module/CLI/test/Factory/ApplicationFactoryTest.php +++ b/module/CLI/test/Factory/ApplicationFactoryTest.php @@ -15,9 +15,7 @@ use function array_merge; class ApplicationFactoryTest extends TestCase { - /** - * @var ApplicationFactory - */ + /** @var ApplicationFactory */ protected $factory; public function setUp() diff --git a/module/Common/src/Collection/PathCollection.php b/module/Common/src/Collection/PathCollection.php index f63102e6..f1dca49a 100644 --- a/module/Common/src/Collection/PathCollection.php +++ b/module/Common/src/Collection/PathCollection.php @@ -9,9 +9,7 @@ use function is_array; final class PathCollection { - /** - * @var array - */ + /** @var array */ private $array; public function __construct(array $array) diff --git a/module/Common/src/IpGeolocation/ChainIpLocationResolver.php b/module/Common/src/IpGeolocation/ChainIpLocationResolver.php index 2b48a70f..6484b577 100644 --- a/module/Common/src/IpGeolocation/ChainIpLocationResolver.php +++ b/module/Common/src/IpGeolocation/ChainIpLocationResolver.php @@ -7,9 +7,7 @@ use Shlinkio\Shlink\Common\Exception\WrongIpException; class ChainIpLocationResolver implements IpLocationResolverInterface { - /** - * @var IpLocationResolverInterface[] - */ + /** @var IpLocationResolverInterface[] */ private $resolvers; public function __construct(IpLocationResolverInterface ...$resolvers) diff --git a/module/Common/src/IpGeolocation/GeoLite2/DbUpdater.php b/module/Common/src/IpGeolocation/GeoLite2/DbUpdater.php index c20ad4ca..b66dd74e 100644 --- a/module/Common/src/IpGeolocation/GeoLite2/DbUpdater.php +++ b/module/Common/src/IpGeolocation/GeoLite2/DbUpdater.php @@ -19,17 +19,11 @@ class DbUpdater implements DbUpdaterInterface private const DB_COMPRESSED_FILE = 'GeoLite2-City.tar.gz'; private const DB_DECOMPRESSED_FILE = 'GeoLite2-City.mmdb'; - /** - * @var ClientInterface - */ + /** @var ClientInterface */ private $httpClient; - /** - * @var Filesystem - */ + /** @var Filesystem */ private $filesystem; - /** - * @var GeoLite2Options - */ + /** @var GeoLite2Options */ private $options; public function __construct(ClientInterface $httpClient, Filesystem $filesystem, GeoLite2Options $options) diff --git a/module/Common/src/IpGeolocation/GeoLite2LocationResolver.php b/module/Common/src/IpGeolocation/GeoLite2LocationResolver.php index 24607ff5..c824f903 100644 --- a/module/Common/src/IpGeolocation/GeoLite2LocationResolver.php +++ b/module/Common/src/IpGeolocation/GeoLite2LocationResolver.php @@ -13,9 +13,7 @@ use function Functional\first; class GeoLite2LocationResolver implements IpLocationResolverInterface { - /** - * @var Reader - */ + /** @var Reader */ private $geoLiteDbReader; public function __construct(Reader $geoLiteDbReader) diff --git a/module/Common/src/IpGeolocation/IpApiLocationResolver.php b/module/Common/src/IpGeolocation/IpApiLocationResolver.php index 8ea8be4b..25b6f774 100644 --- a/module/Common/src/IpGeolocation/IpApiLocationResolver.php +++ b/module/Common/src/IpGeolocation/IpApiLocationResolver.php @@ -14,9 +14,7 @@ class IpApiLocationResolver implements IpLocationResolverInterface { private const SERVICE_PATTERN = 'http://ip-api.com/json/%s'; - /** - * @var Client - */ + /** @var Client */ private $httpClient; public function __construct(Client $httpClient) diff --git a/module/Common/src/Middleware/LocaleMiddleware.php b/module/Common/src/Middleware/LocaleMiddleware.php index 9ac49e00..23ec9b75 100644 --- a/module/Common/src/Middleware/LocaleMiddleware.php +++ b/module/Common/src/Middleware/LocaleMiddleware.php @@ -15,9 +15,7 @@ class LocaleMiddleware implements MiddlewareInterface { private const ACCEPT_LANGUAGE = 'Accept-Language'; - /** - * @var Translator - */ + /** @var Translator */ private $translator; public function __construct(Translator $translator) diff --git a/module/Common/src/Paginator/Adapter/PaginableRepositoryAdapter.php b/module/Common/src/Paginator/Adapter/PaginableRepositoryAdapter.php index 78ce7b53..3e9fe2ef 100644 --- a/module/Common/src/Paginator/Adapter/PaginableRepositoryAdapter.php +++ b/module/Common/src/Paginator/Adapter/PaginableRepositoryAdapter.php @@ -12,21 +12,13 @@ class PaginableRepositoryAdapter implements AdapterInterface { public const ITEMS_PER_PAGE = 10; - /** - * @var PaginableRepositoryInterface - */ + /** @var PaginableRepositoryInterface */ private $paginableRepository; - /** - * @var null|string - */ + /** @var null|string */ private $searchTerm; - /** - * @var null|array|string - */ + /** @var null|array|string */ private $orderBy; - /** - * @var array - */ + /** @var array */ private $tags; public function __construct( diff --git a/module/Common/src/Service/PreviewGenerator.php b/module/Common/src/Service/PreviewGenerator.php index 26ff32fc..3d8206b5 100644 --- a/module/Common/src/Service/PreviewGenerator.php +++ b/module/Common/src/Service/PreviewGenerator.php @@ -12,17 +12,11 @@ use function urlencode; class PreviewGenerator implements PreviewGeneratorInterface { - /** - * @var string - */ + /** @var string */ private $location; - /** - * @var ImageBuilderInterface - */ + /** @var ImageBuilderInterface */ private $imageBuilder; - /** - * @var Filesystem - */ + /** @var Filesystem */ private $filesystem; public function __construct(ImageBuilderInterface $imageBuilder, Filesystem $filesystem, $location) diff --git a/module/Common/src/Template/Extension/TranslatorExtension.php b/module/Common/src/Template/Extension/TranslatorExtension.php index f614ec1f..477730f2 100644 --- a/module/Common/src/Template/Extension/TranslatorExtension.php +++ b/module/Common/src/Template/Extension/TranslatorExtension.php @@ -9,9 +9,7 @@ use Zend\I18n\Translator\TranslatorInterface; class TranslatorExtension implements ExtensionInterface { - /** - * @var TranslatorInterface - */ + /** @var TranslatorInterface */ private $translator; public function __construct(TranslatorInterface $translator) diff --git a/module/Common/src/Util/DateRange.php b/module/Common/src/Util/DateRange.php index 53da7665..34c7b865 100644 --- a/module/Common/src/Util/DateRange.php +++ b/module/Common/src/Util/DateRange.php @@ -7,13 +7,9 @@ use Cake\Chronos\Chronos; final class DateRange { - /** - * @var Chronos|null - */ + /** @var Chronos|null */ private $startDate; - /** - * @var Chronos|null - */ + /** @var Chronos|null */ private $endDate; public function __construct(?Chronos $startDate = null, ?Chronos $endDate = null) diff --git a/module/Common/src/Util/IpAddress.php b/module/Common/src/Util/IpAddress.php index 5e391294..e8f18fdf 100644 --- a/module/Common/src/Util/IpAddress.php +++ b/module/Common/src/Util/IpAddress.php @@ -15,21 +15,13 @@ final class IpAddress private const OBFUSCATED_OCTET = '0'; public const LOCALHOST = '127.0.0.1'; - /** - * @var string - */ + /** @var string */ private $firstOctet; - /** - * @var string - */ + /** @var string */ private $secondOctet; - /** - * @var string - */ + /** @var string */ private $thirdOctet; - /** - * @var string - */ + /** @var string */ private $fourthOctet; private function __construct(string $firstOctet, string $secondOctet, string $thirdOctet, string $fourthOctet) diff --git a/module/Common/test-func/DbUnit/DatabaseTestCase.php b/module/Common/test-func/DbUnit/DatabaseTestCase.php index 89ee871f..b3cb28d6 100644 --- a/module/Common/test-func/DbUnit/DatabaseTestCase.php +++ b/module/Common/test-func/DbUnit/DatabaseTestCase.php @@ -10,9 +10,7 @@ abstract class DatabaseTestCase extends TestCase { protected const ENTITIES_TO_EMPTY = []; - /** - * @var EntityManagerInterface - */ + /** @var EntityManagerInterface */ public static $em; protected function getEntityManager(): EntityManagerInterface diff --git a/module/Common/test/Collection/PathCollectionTest.php b/module/Common/test/Collection/PathCollectionTest.php index 54f8c9a2..dee5d2e7 100644 --- a/module/Common/test/Collection/PathCollectionTest.php +++ b/module/Common/test/Collection/PathCollectionTest.php @@ -8,9 +8,7 @@ use Shlinkio\Shlink\Common\Collection\PathCollection; class PathCollectionTest extends TestCase { - /** - * @var PathCollection - */ + /** @var PathCollection */ private $collection; public function setUp() diff --git a/module/Common/test/ConfigProviderTest.php b/module/Common/test/ConfigProviderTest.php index d8d9dbd7..3e90fef2 100644 --- a/module/Common/test/ConfigProviderTest.php +++ b/module/Common/test/ConfigProviderTest.php @@ -8,9 +8,7 @@ use Shlinkio\Shlink\Common\ConfigProvider; class ConfigProviderTest extends TestCase { - /** - * @var ConfigProvider - */ + /** @var ConfigProvider */ protected $configProvider; public function setUp() diff --git a/module/Common/test/Factory/CacheFactoryTest.php b/module/Common/test/Factory/CacheFactoryTest.php index 4ffa978e..13575bb7 100644 --- a/module/Common/test/Factory/CacheFactoryTest.php +++ b/module/Common/test/Factory/CacheFactoryTest.php @@ -19,9 +19,7 @@ use function sys_get_temp_dir; class CacheFactoryTest extends TestCase { - /** - * @var CacheFactory - */ + /** @var CacheFactory */ protected $factory; public function setUp() diff --git a/module/Common/test/Factory/DottedAccessConfigAbstractFactoryTest.php b/module/Common/test/Factory/DottedAccessConfigAbstractFactoryTest.php index 59bc08e3..4e11f765 100644 --- a/module/Common/test/Factory/DottedAccessConfigAbstractFactoryTest.php +++ b/module/Common/test/Factory/DottedAccessConfigAbstractFactoryTest.php @@ -11,9 +11,7 @@ use Zend\ServiceManager\ServiceManager; class DottedAccessConfigAbstractFactoryTest extends TestCase { - /** - * @var DottedAccessConfigAbstractFactory - */ + /** @var DottedAccessConfigAbstractFactory */ private $factory; public function setUp() diff --git a/module/Common/test/Factory/EmptyResponseImplicitOptionsMiddlewareFactoryTest.php b/module/Common/test/Factory/EmptyResponseImplicitOptionsMiddlewareFactoryTest.php index a9d6c4c4..f687df16 100644 --- a/module/Common/test/Factory/EmptyResponseImplicitOptionsMiddlewareFactoryTest.php +++ b/module/Common/test/Factory/EmptyResponseImplicitOptionsMiddlewareFactoryTest.php @@ -12,9 +12,7 @@ use Zend\ServiceManager\ServiceManager; class EmptyResponseImplicitOptionsMiddlewareFactoryTest extends TestCase { - /** - * @var EmptyResponseImplicitOptionsMiddlewareFactory - */ + /** @var EmptyResponseImplicitOptionsMiddlewareFactory */ protected $factory; public function setUp() diff --git a/module/Common/test/Factory/EntityManagerFactoryTest.php b/module/Common/test/Factory/EntityManagerFactoryTest.php index ec180aad..2647aad9 100644 --- a/module/Common/test/Factory/EntityManagerFactoryTest.php +++ b/module/Common/test/Factory/EntityManagerFactoryTest.php @@ -10,9 +10,7 @@ use Zend\ServiceManager\ServiceManager; class EntityManagerFactoryTest extends TestCase { - /** - * @var EntityManagerFactory - */ + /** @var EntityManagerFactory */ protected $factory; public function setUp() diff --git a/module/Common/test/Factory/LoggerFactoryTest.php b/module/Common/test/Factory/LoggerFactoryTest.php index e5cff954..f57c1078 100644 --- a/module/Common/test/Factory/LoggerFactoryTest.php +++ b/module/Common/test/Factory/LoggerFactoryTest.php @@ -11,9 +11,7 @@ use Zend\ServiceManager\ServiceManager; class LoggerFactoryTest extends TestCase { - /** - * @var LoggerFactory - */ + /** @var LoggerFactory */ protected $factory; public function setUp() diff --git a/module/Common/test/Factory/TranslatorFactoryTest.php b/module/Common/test/Factory/TranslatorFactoryTest.php index 7bc35f16..0dd5cc01 100644 --- a/module/Common/test/Factory/TranslatorFactoryTest.php +++ b/module/Common/test/Factory/TranslatorFactoryTest.php @@ -10,9 +10,7 @@ use Zend\ServiceManager\ServiceManager; class TranslatorFactoryTest extends TestCase { - /** - * @var TranslatorFactory - */ + /** @var TranslatorFactory */ protected $factory; public function setUp() diff --git a/module/Common/test/Image/ImageBuilderFactoryTest.php b/module/Common/test/Image/ImageBuilderFactoryTest.php index 5bfa7e17..1b7488cd 100644 --- a/module/Common/test/Image/ImageBuilderFactoryTest.php +++ b/module/Common/test/Image/ImageBuilderFactoryTest.php @@ -10,9 +10,7 @@ use Zend\ServiceManager\ServiceManager; class ImageBuilderFactoryTest extends TestCase { - /** - * @var ImageBuilderFactory - */ + /** @var ImageBuilderFactory */ protected $factory; public function setUp() diff --git a/module/Common/test/Image/ImageFactoryTest.php b/module/Common/test/Image/ImageFactoryTest.php index 7ccd5bf9..605b2a01 100644 --- a/module/Common/test/Image/ImageFactoryTest.php +++ b/module/Common/test/Image/ImageFactoryTest.php @@ -11,9 +11,7 @@ use Zend\ServiceManager\ServiceManager; class ImageFactoryTest extends TestCase { - /** - * @var ImageFactory - */ + /** @var ImageFactory */ protected $factory; public function setUp() diff --git a/module/Common/test/IpGeolocation/ChainIpLocationResolverTest.php b/module/Common/test/IpGeolocation/ChainIpLocationResolverTest.php index b4933f21..9d0225e0 100644 --- a/module/Common/test/IpGeolocation/ChainIpLocationResolverTest.php +++ b/module/Common/test/IpGeolocation/ChainIpLocationResolverTest.php @@ -11,17 +11,11 @@ use Shlinkio\Shlink\Common\IpGeolocation\IpLocationResolverInterface; class ChainIpLocationResolverTest extends TestCase { - /** - * @var ChainIpLocationResolver - */ + /** @var ChainIpLocationResolver */ private $resolver; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $firstInnerResolver; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $secondInnerResolver; public function setUp() diff --git a/module/Common/test/IpGeolocation/EmptyIpLocationResolverTest.php b/module/Common/test/IpGeolocation/EmptyIpLocationResolverTest.php index c394f85e..e18af901 100644 --- a/module/Common/test/IpGeolocation/EmptyIpLocationResolverTest.php +++ b/module/Common/test/IpGeolocation/EmptyIpLocationResolverTest.php @@ -23,9 +23,7 @@ class EmptyIpLocationResolverTest extends TestCase 'time_zone' => '', ]; - /** - * @var EmptyIpLocationResolver - */ + /** @var EmptyIpLocationResolver */ private $resolver; public function setUp() diff --git a/module/Common/test/IpGeolocation/GeoLite2/DbUpdaterTest.php b/module/Common/test/IpGeolocation/GeoLite2/DbUpdaterTest.php index 116cf5f2..f425a4fd 100644 --- a/module/Common/test/IpGeolocation/GeoLite2/DbUpdaterTest.php +++ b/module/Common/test/IpGeolocation/GeoLite2/DbUpdaterTest.php @@ -17,21 +17,13 @@ use Zend\Diactoros\Response; class DbUpdaterTest extends TestCase { - /** - * @var DbUpdater - */ + /** @var DbUpdater */ private $dbUpdater; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $httpClient; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $filesystem; - /** - * @var GeoLite2Options - */ + /** @var GeoLite2Options */ private $options; public function setUp() diff --git a/module/Common/test/IpGeolocation/GeoLite2LocationResolverTest.php b/module/Common/test/IpGeolocation/GeoLite2LocationResolverTest.php index 65aedaf1..f29854cb 100644 --- a/module/Common/test/IpGeolocation/GeoLite2LocationResolverTest.php +++ b/module/Common/test/IpGeolocation/GeoLite2LocationResolverTest.php @@ -14,13 +14,9 @@ use Shlinkio\Shlink\Common\IpGeolocation\GeoLite2LocationResolver; class GeoLite2LocationResolverTest extends TestCase { - /** - * @var GeoLite2LocationResolver - */ + /** @var GeoLite2LocationResolver */ private $resolver; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $reader; public function setUp() diff --git a/module/Common/test/IpGeolocation/IpApiLocationResolverTest.php b/module/Common/test/IpGeolocation/IpApiLocationResolverTest.php index 999b8fc6..0e00a07f 100644 --- a/module/Common/test/IpGeolocation/IpApiLocationResolverTest.php +++ b/module/Common/test/IpGeolocation/IpApiLocationResolverTest.php @@ -13,13 +13,9 @@ use function json_encode; class IpApiLocationResolverTest extends TestCase { - /** - * @var IpApiLocationResolver - */ + /** @var IpApiLocationResolver */ protected $ipResolver; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $client; public function setUp() diff --git a/module/Common/test/Logger/Processor/ExceptionWithNewLineProcessorTest.php b/module/Common/test/Logger/Processor/ExceptionWithNewLineProcessorTest.php index 1b2943f3..c502e84f 100644 --- a/module/Common/test/Logger/Processor/ExceptionWithNewLineProcessorTest.php +++ b/module/Common/test/Logger/Processor/ExceptionWithNewLineProcessorTest.php @@ -9,9 +9,7 @@ use const PHP_EOL; class ExceptionWithNewLineProcessorTest extends TestCase { - /** - * @var ExceptionWithNewLineProcessor - */ + /** @var ExceptionWithNewLineProcessor */ private $processor; public function setUp() diff --git a/module/Common/test/Middleware/LocaleMiddlewareTest.php b/module/Common/test/Middleware/LocaleMiddlewareTest.php index b06ce23d..5d34da2e 100644 --- a/module/Common/test/Middleware/LocaleMiddlewareTest.php +++ b/module/Common/test/Middleware/LocaleMiddlewareTest.php @@ -11,13 +11,9 @@ use Zend\I18n\Translator\Translator; class LocaleMiddlewareTest extends TestCase { - /** - * @var LocaleMiddleware - */ + /** @var LocaleMiddleware */ protected $middleware; - /** - * @var Translator - */ + /** @var Translator */ protected $translator; public function setUp() diff --git a/module/Common/test/Paginator/PaginableRepositoryAdapterTest.php b/module/Common/test/Paginator/PaginableRepositoryAdapterTest.php index 456f2cd8..da670c9d 100644 --- a/module/Common/test/Paginator/PaginableRepositoryAdapterTest.php +++ b/module/Common/test/Paginator/PaginableRepositoryAdapterTest.php @@ -10,13 +10,9 @@ use Shlinkio\Shlink\Common\Repository\PaginableRepositoryInterface; class PaginableRepositoryAdapterTest extends TestCase { - /** - * @var PaginableRepositoryAdapter - */ + /** @var PaginableRepositoryAdapter */ protected $adapter; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $repo; public function setUp() diff --git a/module/Common/test/Response/PixelResponseTest.php b/module/Common/test/Response/PixelResponseTest.php index 5813a7dc..51f0bc5a 100644 --- a/module/Common/test/Response/PixelResponseTest.php +++ b/module/Common/test/Response/PixelResponseTest.php @@ -8,9 +8,7 @@ use Shlinkio\Shlink\Common\Response\PixelResponse; class PixelResponseTest extends TestCase { - /** - * @var PixelResponse - */ + /** @var PixelResponse */ private $resp; public function setUp() diff --git a/module/Common/test/Service/PreviewGeneratorTest.php b/module/Common/test/Service/PreviewGeneratorTest.php index 882555e1..31cad6f7 100644 --- a/module/Common/test/Service/PreviewGeneratorTest.php +++ b/module/Common/test/Service/PreviewGeneratorTest.php @@ -16,17 +16,11 @@ use function urlencode; class PreviewGeneratorTest extends TestCase { - /** - * @var PreviewGenerator - */ + /** @var PreviewGenerator */ protected $generator; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $image; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $filesystem; public function setUp() diff --git a/module/Common/test/Template/Extension/TranslatorExtensionTest.php b/module/Common/test/Template/Extension/TranslatorExtensionTest.php index c33f43db..28fc2858 100644 --- a/module/Common/test/Template/Extension/TranslatorExtensionTest.php +++ b/module/Common/test/Template/Extension/TranslatorExtensionTest.php @@ -11,9 +11,7 @@ use Zend\I18n\Translator\Translator; class TranslatorExtensionTest extends TestCase { - /** - * @var TranslatorExtension - */ + /** @var TranslatorExtension */ protected $extension; public function setUp() diff --git a/module/Common/test/Type/ChronosDateTimeTypeTest.php b/module/Common/test/Type/ChronosDateTimeTypeTest.php index 2512cab6..1c4e0d6c 100644 --- a/module/Common/test/Type/ChronosDateTimeTypeTest.php +++ b/module/Common/test/Type/ChronosDateTimeTypeTest.php @@ -16,9 +16,7 @@ use stdClass; class ChronosDateTimeTypeTest extends TestCase { - /** - * @var ChronosDateTimeType - */ + /** @var ChronosDateTimeType */ private $type; public function setUp() diff --git a/module/Core/src/Action/AbstractTrackingAction.php b/module/Core/src/Action/AbstractTrackingAction.php index 21ab0b49..7a6fbc0e 100644 --- a/module/Core/src/Action/AbstractTrackingAction.php +++ b/module/Core/src/Action/AbstractTrackingAction.php @@ -19,21 +19,13 @@ use function array_key_exists; abstract class AbstractTrackingAction implements MiddlewareInterface { - /** - * @var UrlShortenerInterface - */ + /** @var UrlShortenerInterface */ private $urlShortener; - /** - * @var VisitsTrackerInterface - */ + /** @var VisitsTrackerInterface */ private $visitTracker; - /** - * @var AppOptions - */ + /** @var AppOptions */ private $appOptions; - /** - * @var LoggerInterface - */ + /** @var LoggerInterface */ private $logger; public function __construct( diff --git a/module/Core/src/Action/PreviewAction.php b/module/Core/src/Action/PreviewAction.php index e8b6cbda..18423f5f 100644 --- a/module/Core/src/Action/PreviewAction.php +++ b/module/Core/src/Action/PreviewAction.php @@ -22,17 +22,11 @@ class PreviewAction implements MiddlewareInterface use ResponseUtilsTrait; use ErrorResponseBuilderTrait; - /** - * @var PreviewGeneratorInterface - */ + /** @var PreviewGeneratorInterface */ private $previewGenerator; - /** - * @var UrlShortenerInterface - */ + /** @var UrlShortenerInterface */ private $urlShortener; - /** - * @var LoggerInterface - */ + /** @var LoggerInterface */ private $logger; public function __construct( diff --git a/module/Core/src/Action/QrCodeAction.php b/module/Core/src/Action/QrCodeAction.php index 26b0e2fe..5cfb3b9d 100644 --- a/module/Core/src/Action/QrCodeAction.php +++ b/module/Core/src/Action/QrCodeAction.php @@ -26,17 +26,11 @@ class QrCodeAction implements MiddlewareInterface private const MIN_SIZE = 50; private const MAX_SIZE = 1000; - /** - * @var RouterInterface - */ + /** @var RouterInterface */ private $router; - /** - * @var UrlShortenerInterface - */ + /** @var UrlShortenerInterface */ private $urlShortener; - /** - * @var LoggerInterface - */ + /** @var LoggerInterface */ private $logger; public function __construct( diff --git a/module/Core/src/Action/RedirectAction.php b/module/Core/src/Action/RedirectAction.php index 83c4312c..1f622543 100644 --- a/module/Core/src/Action/RedirectAction.php +++ b/module/Core/src/Action/RedirectAction.php @@ -17,9 +17,7 @@ class RedirectAction extends AbstractTrackingAction { use ErrorResponseBuilderTrait; - /** - * @var Options\NotFoundShortUrlOptions - */ + /** @var Options\NotFoundShortUrlOptions */ private $notFoundOptions; public function __construct( diff --git a/module/Core/src/Exception/DeleteShortUrlException.php b/module/Core/src/Exception/DeleteShortUrlException.php index d5d9da85..f545ae6a 100644 --- a/module/Core/src/Exception/DeleteShortUrlException.php +++ b/module/Core/src/Exception/DeleteShortUrlException.php @@ -8,9 +8,7 @@ use function sprintf; class DeleteShortUrlException extends RuntimeException { - /** - * @var int - */ + /** @var int */ private $visitsThreshold; public function __construct(int $visitsThreshold, string $message = '', int $code = 0, Throwable $previous = null) diff --git a/module/Core/src/Exception/ValidationException.php b/module/Core/src/Exception/ValidationException.php index fc362303..6ca82c40 100644 --- a/module/Core/src/Exception/ValidationException.php +++ b/module/Core/src/Exception/ValidationException.php @@ -12,9 +12,7 @@ use function sprintf; class ValidationException extends RuntimeException { - /** - * @var array - */ + /** @var array */ private $invalidElements; public function __construct( diff --git a/module/Core/src/Middleware/QrCodeCacheMiddleware.php b/module/Core/src/Middleware/QrCodeCacheMiddleware.php index 2f8bafe8..5ef80f83 100644 --- a/module/Core/src/Middleware/QrCodeCacheMiddleware.php +++ b/module/Core/src/Middleware/QrCodeCacheMiddleware.php @@ -12,9 +12,7 @@ use Zend\Diactoros\Response as DiactResp; class QrCodeCacheMiddleware implements MiddlewareInterface { - /** - * @var Cache - */ + /** @var Cache */ private $cache; public function __construct(Cache $cache) diff --git a/module/Core/src/Model/CreateShortUrlData.php b/module/Core/src/Model/CreateShortUrlData.php index a1d9d018..fa2fbde9 100644 --- a/module/Core/src/Model/CreateShortUrlData.php +++ b/module/Core/src/Model/CreateShortUrlData.php @@ -7,17 +7,11 @@ use Psr\Http\Message\UriInterface; final class CreateShortUrlData { - /** - * @var UriInterface - */ + /** @var UriInterface */ private $longUrl; - /** - * @var array - */ + /** @var array */ private $tags; - /** - * @var ShortUrlMeta - */ + /** @var ShortUrlMeta */ private $meta; public function __construct( diff --git a/module/Core/src/Model/ShortUrlMeta.php b/module/Core/src/Model/ShortUrlMeta.php index 8b8497c3..32df4376 100644 --- a/module/Core/src/Model/ShortUrlMeta.php +++ b/module/Core/src/Model/ShortUrlMeta.php @@ -10,21 +10,13 @@ use function is_string; final class ShortUrlMeta { - /** - * @var Chronos|null - */ + /** @var Chronos|null */ private $validSince; - /** - * @var Chronos|null - */ + /** @var Chronos|null */ private $validUntil; - /** - * @var string|null - */ + /** @var string|null */ private $customSlug; - /** - * @var int|null - */ + /** @var int|null */ private $maxVisits; // Force named constructors diff --git a/module/Core/src/Model/Visitor.php b/module/Core/src/Model/Visitor.php index 82cb3cae..8a8107cf 100644 --- a/module/Core/src/Model/Visitor.php +++ b/module/Core/src/Model/Visitor.php @@ -9,17 +9,11 @@ final class Visitor { public const REMOTE_ADDRESS_ATTR = 'remote_address'; - /** - * @var string - */ + /** @var string */ private $userAgent; - /** - * @var string - */ + /** @var string */ private $referer; - /** - * @var string|null - */ + /** @var string|null */ private $remoteAddress; public function __construct(string $userAgent, string $referer, ?string $remoteAddress) diff --git a/module/Core/src/Options/AppOptions.php b/module/Core/src/Options/AppOptions.php index cdcf5eec..af18c091 100644 --- a/module/Core/src/Options/AppOptions.php +++ b/module/Core/src/Options/AppOptions.php @@ -11,21 +11,13 @@ class AppOptions extends AbstractOptions { use StringUtilsTrait; - /** - * @var string - */ + /** @var string */ protected $name = ''; - /** - * @var string - */ + /** @var string */ protected $version = '1.0'; - /** - * @var string - */ + /** @var string */ protected $secretKey = ''; - /** - * @var string|null - */ + /** @var string|null */ protected $disableTrackParam; /** diff --git a/module/Core/src/Options/NotFoundShortUrlOptions.php b/module/Core/src/Options/NotFoundShortUrlOptions.php index 871c8eff..b894bc50 100644 --- a/module/Core/src/Options/NotFoundShortUrlOptions.php +++ b/module/Core/src/Options/NotFoundShortUrlOptions.php @@ -7,13 +7,9 @@ use Zend\Stdlib\AbstractOptions; class NotFoundShortUrlOptions extends AbstractOptions { - /** - * @var bool - */ + /** @var bool */ private $enableRedirection = false; - /** - * @var string|null - */ + /** @var string|null */ private $redirectTo; public function isRedirectionEnabled(): bool diff --git a/module/Core/src/Response/NotFoundHandler.php b/module/Core/src/Response/NotFoundHandler.php index 733e93de..5696033f 100644 --- a/module/Core/src/Response/NotFoundHandler.php +++ b/module/Core/src/Response/NotFoundHandler.php @@ -17,13 +17,9 @@ class NotFoundHandler implements RequestHandlerInterface { public const NOT_FOUND_TEMPLATE = 'notFoundTemplate'; - /** - * @var TemplateRendererInterface - */ + /** @var TemplateRendererInterface */ private $renderer; - /** - * @var string - */ + /** @var string */ private $defaultTemplate; public function __construct(TemplateRendererInterface $renderer, string $defaultTemplate = 'ShlinkCore::error/404') diff --git a/module/Core/src/Service/ShortUrl/DeleteShortUrlService.php b/module/Core/src/Service/ShortUrl/DeleteShortUrlService.php index 287a5a59..6ff8dbb2 100644 --- a/module/Core/src/Service/ShortUrl/DeleteShortUrlService.php +++ b/module/Core/src/Service/ShortUrl/DeleteShortUrlService.php @@ -12,13 +12,9 @@ class DeleteShortUrlService implements DeleteShortUrlServiceInterface { use FindShortCodeTrait; - /** - * @var EntityManagerInterface - */ + /** @var EntityManagerInterface */ private $em; - /** - * @var DeleteShortUrlsOptions - */ + /** @var DeleteShortUrlsOptions */ private $deleteShortUrlsOptions; public function __construct(EntityManagerInterface $em, DeleteShortUrlsOptions $deleteShortUrlsOptions) diff --git a/module/Core/src/Service/ShortUrlService.php b/module/Core/src/Service/ShortUrlService.php index 763a3b42..17f0a2b2 100644 --- a/module/Core/src/Service/ShortUrlService.php +++ b/module/Core/src/Service/ShortUrlService.php @@ -18,9 +18,7 @@ class ShortUrlService implements ShortUrlServiceInterface use FindShortCodeTrait; use TagManagerTrait; - /** - * @var ORM\EntityManagerInterface - */ + /** @var ORM\EntityManagerInterface */ private $em; public function __construct(ORM\EntityManagerInterface $em) diff --git a/module/Core/src/Service/Tag/TagService.php b/module/Core/src/Service/Tag/TagService.php index 30328738..ef2b48cc 100644 --- a/module/Core/src/Service/Tag/TagService.php +++ b/module/Core/src/Service/Tag/TagService.php @@ -14,9 +14,7 @@ class TagService implements TagServiceInterface { use TagManagerTrait; - /** - * @var ORM\EntityManagerInterface - */ + /** @var ORM\EntityManagerInterface */ private $em; public function __construct(ORM\EntityManagerInterface $em) diff --git a/module/Core/src/Service/UrlShortener.php b/module/Core/src/Service/UrlShortener.php index 219463e7..89627675 100644 --- a/module/Core/src/Service/UrlShortener.php +++ b/module/Core/src/Service/UrlShortener.php @@ -32,25 +32,15 @@ class UrlShortener implements UrlShortenerInterface public const DEFAULT_CHARS = '123456789bcdfghjkmnpqrstvwxyzBCDFGHJKLMNPQRSTVWXYZ'; private const ID_INCREMENT = 200000; - /** - * @var ClientInterface - */ + /** @var ClientInterface */ private $httpClient; - /** - * @var EntityManagerInterface - */ + /** @var EntityManagerInterface */ private $em; - /** - * @var string - */ + /** @var string */ private $chars; - /** - * @var SlugifyInterface - */ + /** @var SlugifyInterface */ private $slugger; - /** - * @var bool - */ + /** @var bool */ private $urlValidationEnabled; public function __construct( diff --git a/module/Core/src/Service/VisitService.php b/module/Core/src/Service/VisitService.php index dea78f0f..a9952e02 100644 --- a/module/Core/src/Service/VisitService.php +++ b/module/Core/src/Service/VisitService.php @@ -11,9 +11,7 @@ use Shlinkio\Shlink\Core\Repository\VisitRepository; class VisitService implements VisitServiceInterface { - /** - * @var EntityManagerInterface - */ + /** @var EntityManagerInterface */ private $em; public function __construct(EntityManagerInterface $em) diff --git a/module/Core/src/Service/VisitsTracker.php b/module/Core/src/Service/VisitsTracker.php index c68f3ce5..4bf8111a 100644 --- a/module/Core/src/Service/VisitsTracker.php +++ b/module/Core/src/Service/VisitsTracker.php @@ -14,9 +14,7 @@ use function sprintf; class VisitsTracker implements VisitsTrackerInterface { - /** - * @var ORM\EntityManagerInterface - */ + /** @var ORM\EntityManagerInterface */ private $em; public function __construct(ORM\EntityManagerInterface $em) diff --git a/module/Core/src/Transformer/ShortUrlDataTransformer.php b/module/Core/src/Transformer/ShortUrlDataTransformer.php index 0a7abe8c..363e533a 100644 --- a/module/Core/src/Transformer/ShortUrlDataTransformer.php +++ b/module/Core/src/Transformer/ShortUrlDataTransformer.php @@ -12,9 +12,7 @@ class ShortUrlDataTransformer implements DataTransformerInterface { use ShortUrlBuilderTrait; - /** - * @var array - */ + /** @var array */ private $domainConfig; public function __construct(array $domainConfig) diff --git a/module/Core/test-func/Repository/ShortUrlRepositoryTest.php b/module/Core/test-func/Repository/ShortUrlRepositoryTest.php index b0f59248..ed03816e 100644 --- a/module/Core/test-func/Repository/ShortUrlRepositoryTest.php +++ b/module/Core/test-func/Repository/ShortUrlRepositoryTest.php @@ -22,9 +22,7 @@ class ShortUrlRepositoryTest extends DatabaseTestCase Tag::class, ]; - /** - * @var ShortUrlRepository - */ + /** @var ShortUrlRepository */ private $repo; public function setUp() diff --git a/module/Core/test-func/Repository/TagRepositoryTest.php b/module/Core/test-func/Repository/TagRepositoryTest.php index 1fce379f..9292753c 100644 --- a/module/Core/test-func/Repository/TagRepositoryTest.php +++ b/module/Core/test-func/Repository/TagRepositoryTest.php @@ -13,9 +13,7 @@ class TagRepositoryTest extends DatabaseTestCase Tag::class, ]; - /** - * @var TagRepository - */ + /** @var TagRepository */ private $repo; protected function setUp() diff --git a/module/Core/test-func/Repository/VisitRepositoryTest.php b/module/Core/test-func/Repository/VisitRepositoryTest.php index 1ef3e7d3..8c6ef11a 100644 --- a/module/Core/test-func/Repository/VisitRepositoryTest.php +++ b/module/Core/test-func/Repository/VisitRepositoryTest.php @@ -21,9 +21,7 @@ class VisitRepositoryTest extends DatabaseTestCase ShortUrl::class, ]; - /** - * @var VisitRepository - */ + /** @var VisitRepository */ private $repo; protected function setUp() diff --git a/module/Core/test/Action/PixelActionTest.php b/module/Core/test/Action/PixelActionTest.php index daaf86fe..164f4a85 100644 --- a/module/Core/test/Action/PixelActionTest.php +++ b/module/Core/test/Action/PixelActionTest.php @@ -18,17 +18,11 @@ use Zend\Diactoros\ServerRequestFactory; class PixelActionTest extends TestCase { - /** - * @var RedirectAction - */ + /** @var RedirectAction */ protected $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $urlShortener; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $visitTracker; public function setUp() diff --git a/module/Core/test/Action/PreviewActionTest.php b/module/Core/test/Action/PreviewActionTest.php index d17fe383..c210cbec 100644 --- a/module/Core/test/Action/PreviewActionTest.php +++ b/module/Core/test/Action/PreviewActionTest.php @@ -23,17 +23,11 @@ use function filesize; class PreviewActionTest extends TestCase { - /** - * @var PreviewAction - */ + /** @var PreviewAction */ protected $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $previewGenerator; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $urlShortener; public function setUp() diff --git a/module/Core/test/Action/QrCodeActionTest.php b/module/Core/test/Action/QrCodeActionTest.php index fc15727a..48cbb19e 100644 --- a/module/Core/test/Action/QrCodeActionTest.php +++ b/module/Core/test/Action/QrCodeActionTest.php @@ -20,13 +20,9 @@ use Zend\Expressive\Router\RouterInterface; class QrCodeActionTest extends TestCase { - /** - * @var QrCodeAction - */ + /** @var QrCodeAction */ protected $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $urlShortener; public function setUp() diff --git a/module/Core/test/Action/RedirectActionTest.php b/module/Core/test/Action/RedirectActionTest.php index cbe87126..e9608c2f 100644 --- a/module/Core/test/Action/RedirectActionTest.php +++ b/module/Core/test/Action/RedirectActionTest.php @@ -19,21 +19,13 @@ use Zend\Diactoros\ServerRequestFactory; class RedirectActionTest extends TestCase { - /** - * @var RedirectAction - */ + /** @var RedirectAction */ private $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $urlShortener; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $visitTracker; - /** - * @var Options\NotFoundShortUrlOptions - */ + /** @var Options\NotFoundShortUrlOptions */ private $notFoundOptions; public function setUp() diff --git a/module/Core/test/ConfigProviderTest.php b/module/Core/test/ConfigProviderTest.php index f3633040..83744bc4 100644 --- a/module/Core/test/ConfigProviderTest.php +++ b/module/Core/test/ConfigProviderTest.php @@ -8,9 +8,7 @@ use Shlinkio\Shlink\Core\ConfigProvider; class ConfigProviderTest extends TestCase { - /** - * @var ConfigProvider - */ + /** @var ConfigProvider */ protected $configProvider; public function setUp() diff --git a/module/Core/test/Middleware/QrCodeCacheMiddlewareTest.php b/module/Core/test/Middleware/QrCodeCacheMiddlewareTest.php index ae701aaf..9820a0db 100644 --- a/module/Core/test/Middleware/QrCodeCacheMiddlewareTest.php +++ b/module/Core/test/Middleware/QrCodeCacheMiddlewareTest.php @@ -15,13 +15,9 @@ use Zend\Diactoros\Uri; class QrCodeCacheMiddlewareTest extends TestCase { - /** - * @var QrCodeCacheMiddleware - */ + /** @var QrCodeCacheMiddleware */ protected $middleware; - /** - * @var Cache - */ + /** @var Cache */ protected $cache; public function setUp() diff --git a/module/Core/test/Response/NotFoundHandlerTest.php b/module/Core/test/Response/NotFoundHandlerTest.php index 80b6171e..dbfcd63a 100644 --- a/module/Core/test/Response/NotFoundHandlerTest.php +++ b/module/Core/test/Response/NotFoundHandlerTest.php @@ -14,13 +14,9 @@ use Zend\Expressive\Template\TemplateRendererInterface; class NotFoundHandlerTest extends TestCase { - /** - * @var NotFoundHandler - */ + /** @var NotFoundHandler */ private $delegate; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $renderer; public function setUp() diff --git a/module/Core/test/Service/ShortUrl/DeleteShortUrlServiceTest.php b/module/Core/test/Service/ShortUrl/DeleteShortUrlServiceTest.php index 60ab0b6d..36c52e01 100644 --- a/module/Core/test/Service/ShortUrl/DeleteShortUrlServiceTest.php +++ b/module/Core/test/Service/ShortUrl/DeleteShortUrlServiceTest.php @@ -20,13 +20,9 @@ use function range; class DeleteShortUrlServiceTest extends TestCase { - /** - * @var DeleteShortUrlService - */ + /** @var DeleteShortUrlService */ private $service; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $em; public function setUp() diff --git a/module/Core/test/Service/ShortUrlServiceTest.php b/module/Core/test/Service/ShortUrlServiceTest.php index 4b8e5ede..82e57da5 100644 --- a/module/Core/test/Service/ShortUrlServiceTest.php +++ b/module/Core/test/Service/ShortUrlServiceTest.php @@ -19,13 +19,9 @@ use function count; class ShortUrlServiceTest extends TestCase { - /** - * @var ShortUrlService - */ + /** @var ShortUrlService */ protected $service; - /** - * @var ObjectProphecy|EntityManagerInterface - */ + /** @var ObjectProphecy|EntityManagerInterface */ protected $em; public function setUp() diff --git a/module/Core/test/Service/Tag/TagServiceTest.php b/module/Core/test/Service/Tag/TagServiceTest.php index 56784353..3ecc7542 100644 --- a/module/Core/test/Service/Tag/TagServiceTest.php +++ b/module/Core/test/Service/Tag/TagServiceTest.php @@ -16,13 +16,9 @@ use Shlinkio\Shlink\Core\Service\Tag\TagService; class TagServiceTest extends TestCase { - /** - * @var TagService - */ + /** @var TagService */ private $service; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $em; public function setUp() diff --git a/module/Core/test/Service/UrlShortenerTest.php b/module/Core/test/Service/UrlShortenerTest.php index 2269ae4a..bae4db91 100644 --- a/module/Core/test/Service/UrlShortenerTest.php +++ b/module/Core/test/Service/UrlShortenerTest.php @@ -23,21 +23,13 @@ use Zend\Diactoros\Uri; class UrlShortenerTest extends TestCase { - /** - * @var UrlShortener - */ + /** @var UrlShortener */ protected $urlShortener; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $em; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $httpClient; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $slugger; public function setUp() diff --git a/module/Core/test/Service/VisitServiceTest.php b/module/Core/test/Service/VisitServiceTest.php index 04a90f84..eb6299a7 100644 --- a/module/Core/test/Service/VisitServiceTest.php +++ b/module/Core/test/Service/VisitServiceTest.php @@ -20,13 +20,9 @@ use function func_get_args; class VisitServiceTest extends TestCase { - /** - * @var VisitService - */ + /** @var VisitService */ protected $visitService; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $em; public function setUp() diff --git a/module/Core/test/Service/VisitsTrackerTest.php b/module/Core/test/Service/VisitsTrackerTest.php index 9d894c04..0cfc78b3 100644 --- a/module/Core/test/Service/VisitsTrackerTest.php +++ b/module/Core/test/Service/VisitsTrackerTest.php @@ -16,13 +16,9 @@ use Shlinkio\Shlink\Core\Service\VisitsTracker; class VisitsTrackerTest extends TestCase { - /** - * @var VisitsTracker - */ + /** @var VisitsTracker */ protected $visitsTracker; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $em; public function setUp() diff --git a/module/Installer/src/Command/InstallCommand.php b/module/Installer/src/Command/InstallCommand.php index f3d9a23c..86361256 100644 --- a/module/Installer/src/Command/InstallCommand.php +++ b/module/Installer/src/Command/InstallCommand.php @@ -28,37 +28,21 @@ class InstallCommand extends Command public const GENERATED_CONFIG_PATH = 'config/params/generated_config.php'; - /** - * @var SymfonyStyle - */ + /** @var SymfonyStyle */ private $io; - /** - * @var ProcessHelper - */ + /** @var ProcessHelper */ private $processHelper; - /** - * @var WriterInterface - */ + /** @var WriterInterface */ private $configWriter; - /** - * @var Filesystem - */ + /** @var Filesystem */ private $filesystem; - /** - * @var ConfigCustomizerManagerInterface - */ + /** @var ConfigCustomizerManagerInterface */ private $configCustomizers; - /** - * @var bool - */ + /** @var bool */ private $isUpdate; - /** - * @var PhpExecutableFinder - */ + /** @var PhpExecutableFinder */ private $phpFinder; - /** - * @var string|bool - */ + /** @var string|bool */ private $phpBinary; /** diff --git a/module/Installer/src/Config/Plugin/DatabaseConfigCustomizer.php b/module/Installer/src/Config/Plugin/DatabaseConfigCustomizer.php index 3b1e27be..d6c82577 100644 --- a/module/Installer/src/Config/Plugin/DatabaseConfigCustomizer.php +++ b/module/Installer/src/Config/Plugin/DatabaseConfigCustomizer.php @@ -38,9 +38,7 @@ class DatabaseConfigCustomizer implements ConfigCustomizerInterface 'SQLite' => 'pdo_sqlite', ]; - /** - * @var Filesystem - */ + /** @var Filesystem */ private $filesystem; public function __construct(Filesystem $filesystem) diff --git a/module/Installer/src/Model/CustomizableAppConfig.php b/module/Installer/src/Model/CustomizableAppConfig.php index 3ee01bc9..c7c6cdd6 100644 --- a/module/Installer/src/Model/CustomizableAppConfig.php +++ b/module/Installer/src/Model/CustomizableAppConfig.php @@ -15,25 +15,15 @@ final class CustomizableAppConfig implements ArraySerializableInterface { public const SQLITE_DB_PATH = 'data/database.sqlite'; - /** - * @var array - */ + /** @var array */ private $database = []; - /** - * @var array - */ + /** @var array */ private $urlShortener = []; - /** - * @var array - */ + /** @var array */ private $language = []; - /** - * @var array - */ + /** @var array */ private $app = []; - /** - * @var string|null - */ + /** @var string|null */ private $importedInstallationPath; public function getDatabase(): array diff --git a/module/Installer/test/Command/InstallCommandTest.php b/module/Installer/test/Command/InstallCommandTest.php index dd3c4220..82965576 100644 --- a/module/Installer/test/Command/InstallCommandTest.php +++ b/module/Installer/test/Command/InstallCommandTest.php @@ -22,21 +22,13 @@ use Zend\Config\Writer\WriterInterface; class InstallCommandTest extends TestCase { - /** - * @var InstallCommand - */ + /** @var InstallCommand */ protected $command; - /** - * @var CommandTester - */ + /** @var CommandTester */ protected $commandTester; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $configWriter; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $filesystem; public function setUp() diff --git a/module/Installer/test/Config/Plugin/ApplicationConfigCustomizerTest.php b/module/Installer/test/Config/Plugin/ApplicationConfigCustomizerTest.php index ddd72814..221f4935 100644 --- a/module/Installer/test/Config/Plugin/ApplicationConfigCustomizerTest.php +++ b/module/Installer/test/Config/Plugin/ApplicationConfigCustomizerTest.php @@ -15,13 +15,9 @@ use function strpos; class ApplicationConfigCustomizerTest extends TestCase { - /** - * @var ApplicationConfigCustomizer - */ + /** @var ApplicationConfigCustomizer */ private $plugin; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $io; public function setUp() diff --git a/module/Installer/test/Config/Plugin/DatabaseConfigCustomizerTest.php b/module/Installer/test/Config/Plugin/DatabaseConfigCustomizerTest.php index 8758083b..104d01b1 100644 --- a/module/Installer/test/Config/Plugin/DatabaseConfigCustomizerTest.php +++ b/module/Installer/test/Config/Plugin/DatabaseConfigCustomizerTest.php @@ -13,17 +13,11 @@ use Symfony\Component\Filesystem\Filesystem; class DatabaseConfigCustomizerTest extends TestCase { - /** - * @var DatabaseConfigCustomizer - */ + /** @var DatabaseConfigCustomizer */ private $plugin; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $io; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $filesystem; public function setUp() diff --git a/module/Installer/test/Config/Plugin/LanguageConfigCustomizerTest.php b/module/Installer/test/Config/Plugin/LanguageConfigCustomizerTest.php index f73b496e..e85f4a04 100644 --- a/module/Installer/test/Config/Plugin/LanguageConfigCustomizerTest.php +++ b/module/Installer/test/Config/Plugin/LanguageConfigCustomizerTest.php @@ -12,13 +12,9 @@ use Symfony\Component\Console\Style\SymfonyStyle; class LanguageConfigCustomizerTest extends TestCase { - /** - * @var LanguageConfigCustomizer - */ + /** @var LanguageConfigCustomizer */ protected $plugin; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $io; public function setUp() diff --git a/module/Installer/test/Config/Plugin/UrlShortenerConfigCustomizerTest.php b/module/Installer/test/Config/Plugin/UrlShortenerConfigCustomizerTest.php index 7ff579be..18a9940e 100644 --- a/module/Installer/test/Config/Plugin/UrlShortenerConfigCustomizerTest.php +++ b/module/Installer/test/Config/Plugin/UrlShortenerConfigCustomizerTest.php @@ -12,13 +12,9 @@ use Symfony\Component\Console\Style\SymfonyStyle; class UrlShortenerConfigCustomizerTest extends TestCase { - /** - * @var UrlShortenerConfigCustomizer - */ + /** @var UrlShortenerConfigCustomizer */ private $plugin; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $io; public function setUp() diff --git a/module/Installer/test/ConfigProviderTest.php b/module/Installer/test/ConfigProviderTest.php index a75a5fe0..5c6c1129 100644 --- a/module/Installer/test/ConfigProviderTest.php +++ b/module/Installer/test/ConfigProviderTest.php @@ -8,9 +8,7 @@ use Shlinkio\Shlink\Installer\ConfigProvider; class ConfigProviderTest extends TestCase { - /** - * @var ConfigProvider - */ + /** @var ConfigProvider */ protected $configProvider; public function setUp() diff --git a/module/Installer/test/Factory/InstallApplicationFactoryTest.php b/module/Installer/test/Factory/InstallApplicationFactoryTest.php index 0cd72393..a4f3ce3d 100644 --- a/module/Installer/test/Factory/InstallApplicationFactoryTest.php +++ b/module/Installer/test/Factory/InstallApplicationFactoryTest.php @@ -11,9 +11,7 @@ use Zend\ServiceManager\ServiceManager; class InstallApplicationFactoryTest extends TestCase { - /** - * @var InstallApplicationFactory - */ + /** @var InstallApplicationFactory */ private $factory; public function setUp() diff --git a/module/Rest/src/Action/AbstractRestAction.php b/module/Rest/src/Action/AbstractRestAction.php index 10b9de2a..21e15d66 100644 --- a/module/Rest/src/Action/AbstractRestAction.php +++ b/module/Rest/src/Action/AbstractRestAction.php @@ -15,9 +15,7 @@ abstract class AbstractRestAction implements RequestHandlerInterface, RequestMet protected const ROUTE_PATH = ''; protected const ROUTE_ALLOWED_METHODS = []; - /** - * @var LoggerInterface - */ + /** @var LoggerInterface */ protected $logger; public function __construct(LoggerInterface $logger = null) diff --git a/module/Rest/src/Action/AuthenticateAction.php b/module/Rest/src/Action/AuthenticateAction.php index e7769219..62a21e99 100644 --- a/module/Rest/src/Action/AuthenticateAction.php +++ b/module/Rest/src/Action/AuthenticateAction.php @@ -17,13 +17,9 @@ class AuthenticateAction extends AbstractRestAction protected const ROUTE_PATH = '/authenticate'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_POST]; - /** - * @var ApiKeyService|ApiKeyServiceInterface - */ + /** @var ApiKeyService|ApiKeyServiceInterface */ private $apiKeyService; - /** - * @var JWTServiceInterface - */ + /** @var JWTServiceInterface */ private $jwtService; public function __construct( diff --git a/module/Rest/src/Action/ShortUrl/AbstractCreateShortUrlAction.php b/module/Rest/src/Action/ShortUrl/AbstractCreateShortUrlAction.php index 0d7f944a..33849c23 100644 --- a/module/Rest/src/Action/ShortUrl/AbstractCreateShortUrlAction.php +++ b/module/Rest/src/Action/ShortUrl/AbstractCreateShortUrlAction.php @@ -20,13 +20,9 @@ use function sprintf; abstract class AbstractCreateShortUrlAction extends AbstractRestAction { - /** - * @var UrlShortenerInterface - */ + /** @var UrlShortenerInterface */ private $urlShortener; - /** - * @var array - */ + /** @var array */ private $domainConfig; public function __construct( diff --git a/module/Rest/src/Action/ShortUrl/DeleteShortUrlAction.php b/module/Rest/src/Action/ShortUrl/DeleteShortUrlAction.php index a53365af..4f7d8e36 100644 --- a/module/Rest/src/Action/ShortUrl/DeleteShortUrlAction.php +++ b/module/Rest/src/Action/ShortUrl/DeleteShortUrlAction.php @@ -19,9 +19,7 @@ class DeleteShortUrlAction extends AbstractRestAction protected const ROUTE_PATH = '/short-urls/{shortCode}'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_DELETE]; - /** - * @var DeleteShortUrlServiceInterface - */ + /** @var DeleteShortUrlServiceInterface */ private $deleteShortUrlService; public function __construct(DeleteShortUrlServiceInterface $deleteShortUrlService, LoggerInterface $logger = null) diff --git a/module/Rest/src/Action/ShortUrl/EditShortUrlAction.php b/module/Rest/src/Action/ShortUrl/EditShortUrlAction.php index ea70855a..bf1d0111 100644 --- a/module/Rest/src/Action/ShortUrl/EditShortUrlAction.php +++ b/module/Rest/src/Action/ShortUrl/EditShortUrlAction.php @@ -20,9 +20,7 @@ class EditShortUrlAction extends AbstractRestAction protected const ROUTE_PATH = '/short-urls/{shortCode}'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_PUT]; - /** - * @var ShortUrlServiceInterface - */ + /** @var ShortUrlServiceInterface */ private $shortUrlService; public function __construct(ShortUrlServiceInterface $shortUrlService, LoggerInterface $logger = null) diff --git a/module/Rest/src/Action/ShortUrl/EditShortUrlTagsAction.php b/module/Rest/src/Action/ShortUrl/EditShortUrlTagsAction.php index 286bc998..099bd92e 100644 --- a/module/Rest/src/Action/ShortUrl/EditShortUrlTagsAction.php +++ b/module/Rest/src/Action/ShortUrl/EditShortUrlTagsAction.php @@ -18,9 +18,7 @@ class EditShortUrlTagsAction extends AbstractRestAction protected const ROUTE_PATH = '/short-urls/{shortCode}/tags'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_PUT]; - /** - * @var ShortUrlServiceInterface - */ + /** @var ShortUrlServiceInterface */ private $shortUrlService; public function __construct(ShortUrlServiceInterface $shortUrlService, LoggerInterface $logger = null) diff --git a/module/Rest/src/Action/ShortUrl/ListShortUrlsAction.php b/module/Rest/src/Action/ShortUrl/ListShortUrlsAction.php index 3e81c60d..bd258273 100644 --- a/module/Rest/src/Action/ShortUrl/ListShortUrlsAction.php +++ b/module/Rest/src/Action/ShortUrl/ListShortUrlsAction.php @@ -21,13 +21,9 @@ class ListShortUrlsAction extends AbstractRestAction protected const ROUTE_PATH = '/short-urls'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_GET]; - /** - * @var ShortUrlServiceInterface - */ + /** @var ShortUrlServiceInterface */ private $shortUrlService; - /** - * @var array - */ + /** @var array */ private $domainConfig; public function __construct( diff --git a/module/Rest/src/Action/ShortUrl/ResolveShortUrlAction.php b/module/Rest/src/Action/ShortUrl/ResolveShortUrlAction.php index 25a640ec..7039df0a 100644 --- a/module/Rest/src/Action/ShortUrl/ResolveShortUrlAction.php +++ b/module/Rest/src/Action/ShortUrl/ResolveShortUrlAction.php @@ -21,13 +21,9 @@ class ResolveShortUrlAction extends AbstractRestAction protected const ROUTE_PATH = '/short-urls/{shortCode}'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_GET]; - /** - * @var UrlShortenerInterface - */ + /** @var UrlShortenerInterface */ private $urlShortener; - /** - * @var array - */ + /** @var array */ private $domainConfig; public function __construct( diff --git a/module/Rest/src/Action/ShortUrl/SingleStepCreateShortUrlAction.php b/module/Rest/src/Action/ShortUrl/SingleStepCreateShortUrlAction.php index cb6284cf..5de188bb 100644 --- a/module/Rest/src/Action/ShortUrl/SingleStepCreateShortUrlAction.php +++ b/module/Rest/src/Action/ShortUrl/SingleStepCreateShortUrlAction.php @@ -16,9 +16,7 @@ class SingleStepCreateShortUrlAction extends AbstractCreateShortUrlAction protected const ROUTE_PATH = '/short-urls/shorten'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_GET]; - /** - * @var ApiKeyServiceInterface - */ + /** @var ApiKeyServiceInterface */ private $apiKeyService; public function __construct( diff --git a/module/Rest/src/Action/Tag/CreateTagsAction.php b/module/Rest/src/Action/Tag/CreateTagsAction.php index 9e963467..05e758dc 100644 --- a/module/Rest/src/Action/Tag/CreateTagsAction.php +++ b/module/Rest/src/Action/Tag/CreateTagsAction.php @@ -15,9 +15,7 @@ class CreateTagsAction extends AbstractRestAction protected const ROUTE_PATH = '/tags'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_POST]; - /** - * @var TagServiceInterface - */ + /** @var TagServiceInterface */ private $tagService; public function __construct(TagServiceInterface $tagService, LoggerInterface $logger = null) diff --git a/module/Rest/src/Action/Tag/DeleteTagsAction.php b/module/Rest/src/Action/Tag/DeleteTagsAction.php index 4c1f4371..67764871 100644 --- a/module/Rest/src/Action/Tag/DeleteTagsAction.php +++ b/module/Rest/src/Action/Tag/DeleteTagsAction.php @@ -15,9 +15,7 @@ class DeleteTagsAction extends AbstractRestAction protected const ROUTE_PATH = '/tags'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_DELETE]; - /** - * @var TagServiceInterface - */ + /** @var TagServiceInterface */ private $tagService; public function __construct(TagServiceInterface $tagService, LoggerInterface $logger = null) diff --git a/module/Rest/src/Action/Tag/ListTagsAction.php b/module/Rest/src/Action/Tag/ListTagsAction.php index 02fb968c..bf0e7751 100644 --- a/module/Rest/src/Action/Tag/ListTagsAction.php +++ b/module/Rest/src/Action/Tag/ListTagsAction.php @@ -15,9 +15,7 @@ class ListTagsAction extends AbstractRestAction protected const ROUTE_PATH = '/tags'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_GET]; - /** - * @var TagServiceInterface - */ + /** @var TagServiceInterface */ private $tagService; public function __construct(TagServiceInterface $tagService, LoggerInterface $logger = null) diff --git a/module/Rest/src/Action/Tag/UpdateTagAction.php b/module/Rest/src/Action/Tag/UpdateTagAction.php index 7fb155cb..2591452c 100644 --- a/module/Rest/src/Action/Tag/UpdateTagAction.php +++ b/module/Rest/src/Action/Tag/UpdateTagAction.php @@ -19,9 +19,7 @@ class UpdateTagAction extends AbstractRestAction protected const ROUTE_PATH = '/tags'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_PUT]; - /** - * @var TagServiceInterface - */ + /** @var TagServiceInterface */ private $tagService; public function __construct(TagServiceInterface $tagService, LoggerInterface $logger = null) diff --git a/module/Rest/src/Action/Visit/GetVisitsAction.php b/module/Rest/src/Action/Visit/GetVisitsAction.php index c705a80f..bddc113d 100644 --- a/module/Rest/src/Action/Visit/GetVisitsAction.php +++ b/module/Rest/src/Action/Visit/GetVisitsAction.php @@ -21,9 +21,7 @@ class GetVisitsAction extends AbstractRestAction protected const ROUTE_PATH = '/short-urls/{shortCode}/visits'; protected const ROUTE_ALLOWED_METHODS = [self::METHOD_GET]; - /** - * @var VisitsTrackerInterface - */ + /** @var VisitsTrackerInterface */ private $visitsTracker; public function __construct(VisitsTrackerInterface $visitsTracker, LoggerInterface $logger = null) diff --git a/module/Rest/src/Authentication/JWTService.php b/module/Rest/src/Authentication/JWTService.php index cf597445..d1182f9f 100644 --- a/module/Rest/src/Authentication/JWTService.php +++ b/module/Rest/src/Authentication/JWTService.php @@ -12,9 +12,7 @@ use function time; class JWTService implements JWTServiceInterface { - /** - * @var AppOptions - */ + /** @var AppOptions */ private $appOptions; public function __construct(AppOptions $appOptions) diff --git a/module/Rest/src/Authentication/Plugin/ApiKeyHeaderPlugin.php b/module/Rest/src/Authentication/Plugin/ApiKeyHeaderPlugin.php index 6ad5877e..c507cdd5 100644 --- a/module/Rest/src/Authentication/Plugin/ApiKeyHeaderPlugin.php +++ b/module/Rest/src/Authentication/Plugin/ApiKeyHeaderPlugin.php @@ -13,9 +13,7 @@ class ApiKeyHeaderPlugin implements AuthenticationPluginInterface { public const HEADER_NAME = 'X-Api-Key'; - /** - * @var ApiKeyServiceInterface - */ + /** @var ApiKeyServiceInterface */ private $apiKeyService; public function __construct(ApiKeyServiceInterface $apiKeyService) diff --git a/module/Rest/src/Authentication/Plugin/AuthorizationHeaderPlugin.php b/module/Rest/src/Authentication/Plugin/AuthorizationHeaderPlugin.php index 2be02f6b..cecb29db 100644 --- a/module/Rest/src/Authentication/Plugin/AuthorizationHeaderPlugin.php +++ b/module/Rest/src/Authentication/Plugin/AuthorizationHeaderPlugin.php @@ -18,9 +18,7 @@ class AuthorizationHeaderPlugin implements AuthenticationPluginInterface { public const HEADER_NAME = 'Authorization'; - /** - * @var JWTServiceInterface - */ + /** @var JWTServiceInterface */ private $jwtService; public function __construct(JWTServiceInterface $jwtService) diff --git a/module/Rest/src/Authentication/RequestToHttpAuthPlugin.php b/module/Rest/src/Authentication/RequestToHttpAuthPlugin.php index 3be4b60a..4466ee42 100644 --- a/module/Rest/src/Authentication/RequestToHttpAuthPlugin.php +++ b/module/Rest/src/Authentication/RequestToHttpAuthPlugin.php @@ -19,9 +19,7 @@ class RequestToHttpAuthPlugin implements RequestToHttpAuthPluginInterface Plugin\AuthorizationHeaderPlugin::HEADER_NAME, ]; - /** - * @var AuthenticationPluginManagerInterface - */ + /** @var AuthenticationPluginManagerInterface */ private $authPluginManager; public function __construct(AuthenticationPluginManagerInterface $authPluginManager) diff --git a/module/Rest/src/Exception/VerifyAuthenticationException.php b/module/Rest/src/Exception/VerifyAuthenticationException.php index 5aee03b4..71004fa3 100644 --- a/module/Rest/src/Exception/VerifyAuthenticationException.php +++ b/module/Rest/src/Exception/VerifyAuthenticationException.php @@ -8,13 +8,9 @@ use function sprintf; class VerifyAuthenticationException extends RuntimeException { - /** - * @var string - */ + /** @var string */ private $errorCode; - /** - * @var string - */ + /** @var string */ private $publicMessage; public function __construct( diff --git a/module/Rest/src/Middleware/AuthenticationMiddleware.php b/module/Rest/src/Middleware/AuthenticationMiddleware.php index f19fc5d0..d92a3eb4 100644 --- a/module/Rest/src/Middleware/AuthenticationMiddleware.php +++ b/module/Rest/src/Middleware/AuthenticationMiddleware.php @@ -25,17 +25,11 @@ use function sprintf; class AuthenticationMiddleware implements MiddlewareInterface, StatusCodeInterface, RequestMethodInterface { - /** - * @var LoggerInterface - */ + /** @var LoggerInterface */ private $logger; - /** - * @var array - */ + /** @var array */ private $routesWhitelist; - /** - * @var RequestToHttpAuthPluginInterface - */ + /** @var RequestToHttpAuthPluginInterface */ private $requestToAuthPlugin; public function __construct( diff --git a/module/Rest/src/Service/ApiKeyService.php b/module/Rest/src/Service/ApiKeyService.php index d1d6a42f..b5c8d96e 100644 --- a/module/Rest/src/Service/ApiKeyService.php +++ b/module/Rest/src/Service/ApiKeyService.php @@ -11,9 +11,7 @@ use function sprintf; class ApiKeyService implements ApiKeyServiceInterface { - /** - * @var EntityManagerInterface - */ + /** @var EntityManagerInterface */ private $em; public function __construct(EntityManagerInterface $em) diff --git a/module/Rest/test/Action/AuthenticateActionTest.php b/module/Rest/test/Action/AuthenticateActionTest.php index e282c46e..38fc3cda 100644 --- a/module/Rest/test/Action/AuthenticateActionTest.php +++ b/module/Rest/test/Action/AuthenticateActionTest.php @@ -15,17 +15,11 @@ use function strpos; class AuthenticateActionTest extends TestCase { - /** - * @var AuthenticateAction - */ + /** @var AuthenticateAction */ protected $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $apiKeyService; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $jwtService; public function setUp() diff --git a/module/Rest/test/Action/ShortUrl/CreateShortUrlActionTest.php b/module/Rest/test/Action/ShortUrl/CreateShortUrlActionTest.php index b523cf25..252a0300 100644 --- a/module/Rest/test/Action/ShortUrl/CreateShortUrlActionTest.php +++ b/module/Rest/test/Action/ShortUrl/CreateShortUrlActionTest.php @@ -19,13 +19,9 @@ use function strpos; class CreateShortUrlActionTest extends TestCase { - /** - * @var CreateShortUrlAction - */ + /** @var CreateShortUrlAction */ protected $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $urlShortener; public function setUp() diff --git a/module/Rest/test/Action/ShortUrl/DeleteShortUrlActionTest.php b/module/Rest/test/Action/ShortUrl/DeleteShortUrlActionTest.php index 0eaddc7c..bf43c4c1 100644 --- a/module/Rest/test/Action/ShortUrl/DeleteShortUrlActionTest.php +++ b/module/Rest/test/Action/ShortUrl/DeleteShortUrlActionTest.php @@ -16,13 +16,9 @@ use Zend\Diactoros\ServerRequestFactory; class DeleteShortUrlActionTest extends TestCase { - /** - * @var DeleteShortUrlAction - */ + /** @var DeleteShortUrlAction */ private $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $service; public function setUp() diff --git a/module/Rest/test/Action/ShortUrl/EditShortUrlActionTest.php b/module/Rest/test/Action/ShortUrl/EditShortUrlActionTest.php index 2627abb0..0206e1bd 100644 --- a/module/Rest/test/Action/ShortUrl/EditShortUrlActionTest.php +++ b/module/Rest/test/Action/ShortUrl/EditShortUrlActionTest.php @@ -16,13 +16,9 @@ use Zend\Diactoros\ServerRequestFactory; class EditShortUrlActionTest extends TestCase { - /** - * @var EditShortUrlAction - */ + /** @var EditShortUrlAction */ private $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $shortUrlService; public function setUp() diff --git a/module/Rest/test/Action/ShortUrl/EditShortUrlTagsActionTest.php b/module/Rest/test/Action/ShortUrl/EditShortUrlTagsActionTest.php index bbdb84ff..f2976e70 100644 --- a/module/Rest/test/Action/ShortUrl/EditShortUrlTagsActionTest.php +++ b/module/Rest/test/Action/ShortUrl/EditShortUrlTagsActionTest.php @@ -13,13 +13,9 @@ use Zend\Diactoros\ServerRequestFactory; class EditShortUrlTagsActionTest extends TestCase { - /** - * @var EditShortUrlTagsAction - */ + /** @var EditShortUrlTagsAction */ protected $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $shortUrlService; public function setUp() diff --git a/module/Rest/test/Action/ShortUrl/ListShortUrlsActionTest.php b/module/Rest/test/Action/ShortUrl/ListShortUrlsActionTest.php index dc416523..ebd921ba 100644 --- a/module/Rest/test/Action/ShortUrl/ListShortUrlsActionTest.php +++ b/module/Rest/test/Action/ShortUrl/ListShortUrlsActionTest.php @@ -14,13 +14,9 @@ use Zend\Paginator\Paginator; class ListShortUrlsActionTest extends TestCase { - /** - * @var ListShortUrlsAction - */ + /** @var ListShortUrlsAction */ protected $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $service; public function setUp() diff --git a/module/Rest/test/Action/ShortUrl/ResolveShortUrlActionTest.php b/module/Rest/test/Action/ShortUrl/ResolveShortUrlActionTest.php index 97ffdbb0..32419d04 100644 --- a/module/Rest/test/Action/ShortUrl/ResolveShortUrlActionTest.php +++ b/module/Rest/test/Action/ShortUrl/ResolveShortUrlActionTest.php @@ -17,13 +17,9 @@ use function strpos; class ResolveShortUrlActionTest extends TestCase { - /** - * @var ResolveShortUrlAction - */ + /** @var ResolveShortUrlAction */ protected $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $urlShortener; public function setUp() diff --git a/module/Rest/test/Action/ShortUrl/SingleStepCreateShortUrlActionTest.php b/module/Rest/test/Action/ShortUrl/SingleStepCreateShortUrlActionTest.php index 8edc79ea..cf5bf4ad 100644 --- a/module/Rest/test/Action/ShortUrl/SingleStepCreateShortUrlActionTest.php +++ b/module/Rest/test/Action/ShortUrl/SingleStepCreateShortUrlActionTest.php @@ -17,17 +17,11 @@ use Zend\Diactoros\ServerRequestFactory; class SingleStepCreateShortUrlActionTest extends TestCase { - /** - * @var SingleStepCreateShortUrlAction - */ + /** @var SingleStepCreateShortUrlAction */ private $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $urlShortener; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $apiKeyService; public function setUp() diff --git a/module/Rest/test/Action/Tag/CreateTagsActionTest.php b/module/Rest/test/Action/Tag/CreateTagsActionTest.php index e94a0ea8..a3c7871f 100644 --- a/module/Rest/test/Action/Tag/CreateTagsActionTest.php +++ b/module/Rest/test/Action/Tag/CreateTagsActionTest.php @@ -13,13 +13,9 @@ use Zend\Diactoros\ServerRequestFactory; class CreateTagsActionTest extends TestCase { - /** - * @var CreateTagsAction - */ + /** @var CreateTagsAction */ private $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $tagService; public function setUp() diff --git a/module/Rest/test/Action/Tag/DeleteTagsActionTest.php b/module/Rest/test/Action/Tag/DeleteTagsActionTest.php index fc376576..b8b47da0 100644 --- a/module/Rest/test/Action/Tag/DeleteTagsActionTest.php +++ b/module/Rest/test/Action/Tag/DeleteTagsActionTest.php @@ -12,13 +12,9 @@ use Zend\Diactoros\ServerRequestFactory; class DeleteTagsActionTest extends TestCase { - /** - * @var DeleteTagsAction - */ + /** @var DeleteTagsAction */ private $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $tagService; public function setUp() diff --git a/module/Rest/test/Action/Tag/ListTagsActionTest.php b/module/Rest/test/Action/Tag/ListTagsActionTest.php index db3c52c8..fa26a83c 100644 --- a/module/Rest/test/Action/Tag/ListTagsActionTest.php +++ b/module/Rest/test/Action/Tag/ListTagsActionTest.php @@ -14,13 +14,9 @@ use function Shlinkio\Shlink\Common\json_decode; class ListTagsActionTest extends TestCase { - /** - * @var ListTagsAction - */ + /** @var ListTagsAction */ private $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $tagService; public function setUp() diff --git a/module/Rest/test/Action/Tag/UpdateTagActionTest.php b/module/Rest/test/Action/Tag/UpdateTagActionTest.php index 1e460a5a..a5649fa2 100644 --- a/module/Rest/test/Action/Tag/UpdateTagActionTest.php +++ b/module/Rest/test/Action/Tag/UpdateTagActionTest.php @@ -14,13 +14,9 @@ use Zend\Diactoros\ServerRequestFactory; class UpdateTagActionTest extends TestCase { - /** - * @var UpdateTagAction - */ + /** @var UpdateTagAction */ private $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $tagService; public function setUp() diff --git a/module/Rest/test/Action/Visit/GetVisitsActionTest.php b/module/Rest/test/Action/Visit/GetVisitsActionTest.php index dd76c928..859c9657 100644 --- a/module/Rest/test/Action/Visit/GetVisitsActionTest.php +++ b/module/Rest/test/Action/Visit/GetVisitsActionTest.php @@ -16,13 +16,9 @@ use Zend\Diactoros\ServerRequestFactory; class GetVisitsActionTest extends TestCase { - /** - * @var GetVisitsAction - */ + /** @var GetVisitsAction */ protected $action; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $visitsTracker; public function setUp() diff --git a/module/Rest/test/Authentication/AuthenticationPluginManagerFactoryTest.php b/module/Rest/test/Authentication/AuthenticationPluginManagerFactoryTest.php index 0a1b3993..e932deb2 100644 --- a/module/Rest/test/Authentication/AuthenticationPluginManagerFactoryTest.php +++ b/module/Rest/test/Authentication/AuthenticationPluginManagerFactoryTest.php @@ -10,9 +10,7 @@ use Zend\ServiceManager\ServiceManager; class AuthenticationPluginManagerFactoryTest extends TestCase { - /** - * @var AuthenticationPluginManagerFactory - */ + /** @var AuthenticationPluginManagerFactory */ private $factory; public function setUp() diff --git a/module/Rest/test/Authentication/JWTServiceTest.php b/module/Rest/test/Authentication/JWTServiceTest.php index 64812613..5ff66268 100644 --- a/module/Rest/test/Authentication/JWTServiceTest.php +++ b/module/Rest/test/Authentication/JWTServiceTest.php @@ -12,9 +12,7 @@ use function time; class JWTServiceTest extends TestCase { - /** - * @var JWTService - */ + /** @var JWTService */ protected $service; public function setUp() diff --git a/module/Rest/test/Authentication/Plugin/ApiKeyHeaderPluginTest.php b/module/Rest/test/Authentication/Plugin/ApiKeyHeaderPluginTest.php index 51149a41..952eb755 100644 --- a/module/Rest/test/Authentication/Plugin/ApiKeyHeaderPluginTest.php +++ b/module/Rest/test/Authentication/Plugin/ApiKeyHeaderPluginTest.php @@ -14,13 +14,9 @@ use Zend\Diactoros\ServerRequestFactory; class ApiKeyHeaderPluginTest extends TestCase { - /** - * @var ApiKeyHeaderPlugin - */ + /** @var ApiKeyHeaderPlugin */ private $plugin; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $apiKeyService; public function setUp() diff --git a/module/Rest/test/Authentication/Plugin/AuthorizationHeaderPluginTest.php b/module/Rest/test/Authentication/Plugin/AuthorizationHeaderPluginTest.php index 716f5d87..bc7bf86c 100644 --- a/module/Rest/test/Authentication/Plugin/AuthorizationHeaderPluginTest.php +++ b/module/Rest/test/Authentication/Plugin/AuthorizationHeaderPluginTest.php @@ -14,13 +14,9 @@ use function sprintf; class AuthorizationHeaderPluginTest extends TestCase { - /** - * @var AuthorizationHeaderPlugin - */ + /** @var AuthorizationHeaderPlugin */ private $plugin; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $jwtService; public function setUp() diff --git a/module/Rest/test/Authentication/RequestToAuthPluginTest.php b/module/Rest/test/Authentication/RequestToAuthPluginTest.php index 59f1f5c1..3b3b80b5 100644 --- a/module/Rest/test/Authentication/RequestToAuthPluginTest.php +++ b/module/Rest/test/Authentication/RequestToAuthPluginTest.php @@ -17,13 +17,9 @@ use function sprintf; class RequestToAuthPluginTest extends TestCase { - /** - * @var RequestToHttpAuthPlugin - */ + /** @var RequestToHttpAuthPlugin */ private $requestToPlugin; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ private $pluginManager; public function setUp() diff --git a/module/Rest/test/ConfigProviderTest.php b/module/Rest/test/ConfigProviderTest.php index 6fef55ef..1b4cbdd3 100644 --- a/module/Rest/test/ConfigProviderTest.php +++ b/module/Rest/test/ConfigProviderTest.php @@ -8,9 +8,7 @@ use Shlinkio\Shlink\Rest\ConfigProvider; class ConfigProviderTest extends TestCase { - /** - * @var ConfigProvider - */ + /** @var ConfigProvider */ protected $configProvider; public function setUp() diff --git a/module/Rest/test/ErrorHandler/JsonErrorResponseGeneratorTest.php b/module/Rest/test/ErrorHandler/JsonErrorResponseGeneratorTest.php index 7c0eaaff..346d2822 100644 --- a/module/Rest/test/ErrorHandler/JsonErrorResponseGeneratorTest.php +++ b/module/Rest/test/ErrorHandler/JsonErrorResponseGeneratorTest.php @@ -10,9 +10,7 @@ use Zend\Diactoros\ServerRequestFactory; class JsonErrorResponseGeneratorTest extends TestCase { - /** - * @var JsonErrorResponseGenerator - */ + /** @var JsonErrorResponseGenerator */ protected $errorHandler; public function setUp() diff --git a/module/Rest/test/Middleware/AuthenticationMiddlewareTest.php b/module/Rest/test/Middleware/AuthenticationMiddlewareTest.php index a3434ff7..8ff36454 100644 --- a/module/Rest/test/Middleware/AuthenticationMiddlewareTest.php +++ b/module/Rest/test/Middleware/AuthenticationMiddlewareTest.php @@ -31,18 +31,12 @@ use function Zend\Stratigility\middleware; class AuthenticationMiddlewareTest extends TestCase { - /** - * @var AuthenticationMiddleware - */ + /** @var AuthenticationMiddleware */ protected $middleware; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $requestToPlugin; - /** - * @var callable - */ + /** @var callable */ protected $dummyMiddleware; public function setUp() diff --git a/module/Rest/test/Middleware/BodyParserMiddlewareTest.php b/module/Rest/test/Middleware/BodyParserMiddlewareTest.php index 2705e84b..3cf95130 100644 --- a/module/Rest/test/Middleware/BodyParserMiddlewareTest.php +++ b/module/Rest/test/Middleware/BodyParserMiddlewareTest.php @@ -16,9 +16,7 @@ use function array_shift; class BodyParserMiddlewareTest extends TestCase { - /** - * @var BodyParserMiddleware - */ + /** @var BodyParserMiddleware */ private $middleware; public function setUp() diff --git a/module/Rest/test/Middleware/CrossDomainMiddlewareTest.php b/module/Rest/test/Middleware/CrossDomainMiddlewareTest.php index ea5bf941..aeacf156 100644 --- a/module/Rest/test/Middleware/CrossDomainMiddlewareTest.php +++ b/module/Rest/test/Middleware/CrossDomainMiddlewareTest.php @@ -13,13 +13,9 @@ use Zend\Diactoros\ServerRequestFactory; class CrossDomainMiddlewareTest extends TestCase { - /** - * @var CrossDomainMiddleware - */ + /** @var CrossDomainMiddleware */ protected $middleware; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $delegate; public function setUp() diff --git a/module/Rest/test/Middleware/PathVersionMiddlewareTest.php b/module/Rest/test/Middleware/PathVersionMiddlewareTest.php index 3b0e8894..14f41b61 100644 --- a/module/Rest/test/Middleware/PathVersionMiddlewareTest.php +++ b/module/Rest/test/Middleware/PathVersionMiddlewareTest.php @@ -16,9 +16,7 @@ use function array_shift; class PathVersionMiddlewareTest extends TestCase { - /** - * @var PathVersionMiddleware - */ + /** @var PathVersionMiddleware */ protected $middleware; public function setUp() diff --git a/module/Rest/test/Middleware/ShortUrl/CreateShortUrlContentNegotiationMiddlewareTest.php b/module/Rest/test/Middleware/ShortUrl/CreateShortUrlContentNegotiationMiddlewareTest.php index bb2dc7ad..86c71e86 100644 --- a/module/Rest/test/Middleware/ShortUrl/CreateShortUrlContentNegotiationMiddlewareTest.php +++ b/module/Rest/test/Middleware/ShortUrl/CreateShortUrlContentNegotiationMiddlewareTest.php @@ -14,13 +14,9 @@ use Zend\Diactoros\ServerRequestFactory; class CreateShortUrlContentNegotiationMiddlewareTest extends TestCase { - /** - * @var CreateShortUrlContentNegotiationMiddleware - */ + /** @var CreateShortUrlContentNegotiationMiddleware */ private $middleware; - /** - * @var RequestHandlerInterface - */ + /** @var RequestHandlerInterface */ private $requestHandler; public function setUp() diff --git a/module/Rest/test/Service/ApiKeyServiceTest.php b/module/Rest/test/Service/ApiKeyServiceTest.php index 74109eca..78b8a8be 100644 --- a/module/Rest/test/Service/ApiKeyServiceTest.php +++ b/module/Rest/test/Service/ApiKeyServiceTest.php @@ -14,13 +14,9 @@ use Shlinkio\Shlink\Rest\Service\ApiKeyService; class ApiKeyServiceTest extends TestCase { - /** - * @var ApiKeyService - */ + /** @var ApiKeyService */ protected $service; - /** - * @var ObjectProphecy - */ + /** @var ObjectProphecy */ protected $em; public function setUp() diff --git a/phpcs.xml b/phpcs.xml index 2d4d3e65..e1d56d5a 100644 --- a/phpcs.xml +++ b/phpcs.xml @@ -46,6 +46,8 @@ + + bin