diff --git a/module/Rest/config/dependencies.config.php b/module/Rest/config/dependencies.config.php index f6af6f85..1daa9300 100644 --- a/module/Rest/config/dependencies.config.php +++ b/module/Rest/config/dependencies.config.php @@ -28,7 +28,7 @@ return [ Action\ShortUrl\ResolveShortUrlAction::class => ConfigAbstractFactory::class, Action\ShortUrl\ListShortUrlsAction::class => ConfigAbstractFactory::class, Action\ShortUrl\EditShortUrlTagsAction::class => ConfigAbstractFactory::class, - Action\Visit\GetVisitsAction::class => ConfigAbstractFactory::class, + Action\Visit\ShortUrlVisitsAction::class => ConfigAbstractFactory::class, Action\Tag\ListTagsAction::class => ConfigAbstractFactory::class, Action\Tag\DeleteTagsAction::class => ConfigAbstractFactory::class, Action\Tag\CreateTagsAction::class => ConfigAbstractFactory::class, @@ -65,7 +65,7 @@ return [ Service\ShortUrl\ShortUrlResolver::class, 'config.url_shortener.domain', ], - Action\Visit\GetVisitsAction::class => [Service\VisitsTracker::class, 'Logger_Shlink'], + Action\Visit\ShortUrlVisitsAction::class => [Service\VisitsTracker::class, 'Logger_Shlink'], Action\ShortUrl\ListShortUrlsAction::class => [ Service\ShortUrlService::class, 'config.url_shortener.domain', diff --git a/module/Rest/config/routes.config.php b/module/Rest/config/routes.config.php index 3ced8357..7498d1b3 100644 --- a/module/Rest/config/routes.config.php +++ b/module/Rest/config/routes.config.php @@ -26,7 +26,7 @@ return [ Action\ShortUrl\EditShortUrlTagsAction::getRouteDef([$dropDomainMiddleware]), // Visits - Action\Visit\GetVisitsAction::getRouteDef([$dropDomainMiddleware]), + Action\Visit\ShortUrlVisitsAction::getRouteDef([$dropDomainMiddleware]), // Tags Action\Tag\ListTagsAction::getRouteDef(), diff --git a/module/Rest/src/Action/Visit/GetVisitsAction.php b/module/Rest/src/Action/Visit/ShortUrlVisitsAction.php similarity index 96% rename from module/Rest/src/Action/Visit/GetVisitsAction.php rename to module/Rest/src/Action/Visit/ShortUrlVisitsAction.php index bd6ae5a5..f7f0224a 100644 --- a/module/Rest/src/Action/Visit/GetVisitsAction.php +++ b/module/Rest/src/Action/Visit/ShortUrlVisitsAction.php @@ -14,7 +14,7 @@ use Shlinkio\Shlink\Core\Model\VisitsParams; use Shlinkio\Shlink\Core\Service\VisitsTrackerInterface; use Shlinkio\Shlink\Rest\Action\AbstractRestAction; -class GetVisitsAction extends AbstractRestAction +class ShortUrlVisitsAction extends AbstractRestAction { use PaginatorUtilsTrait; diff --git a/module/Rest/test/Action/Visit/GetVisitsActionTest.php b/module/Rest/test/Action/Visit/ShortUrlVisitsActionTest.php similarity index 89% rename from module/Rest/test/Action/Visit/GetVisitsActionTest.php rename to module/Rest/test/Action/Visit/ShortUrlVisitsActionTest.php index a1f1681a..07508acf 100644 --- a/module/Rest/test/Action/Visit/GetVisitsActionTest.php +++ b/module/Rest/test/Action/Visit/ShortUrlVisitsActionTest.php @@ -15,17 +15,17 @@ use Shlinkio\Shlink\Common\Util\DateRange; use Shlinkio\Shlink\Core\Model\ShortUrlIdentifier; use Shlinkio\Shlink\Core\Model\VisitsParams; use Shlinkio\Shlink\Core\Service\VisitsTracker; -use Shlinkio\Shlink\Rest\Action\Visit\GetVisitsAction; +use Shlinkio\Shlink\Rest\Action\Visit\ShortUrlVisitsAction; -class GetVisitsActionTest extends TestCase +class ShortUrlVisitsActionTest extends TestCase { - private GetVisitsAction $action; + private ShortUrlVisitsAction $action; private ObjectProphecy $visitsTracker; public function setUp(): void { $this->visitsTracker = $this->prophesize(VisitsTracker::class); - $this->action = new GetVisitsAction($this->visitsTracker->reveal()); + $this->action = new ShortUrlVisitsAction($this->visitsTracker->reveal()); } /** @test */