Skip to content
This repository was archived by the owner on May 1, 2019. It is now read-only.

Commit b561121

Browse files
committed
Fix: Rename config key and service identifier
1 parent 29ac5ed commit b561121

File tree

6 files changed

+7
-7
lines changed

6 files changed

+7
-7
lines changed

module/Application/config/module.config.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
use Psr\Log;
77

88
return [
9-
'github_repository' => [
9+
'project_github_repository' => [
1010
'owner' => 'zendframework',
1111
'name' => 'modules.zendframework.com',
1212
],
@@ -97,8 +97,8 @@
9797
'service_manager' => [
9898
'factories' => [
9999
\HTMLPurifier::class => Service\HtmlPurifierFactory::class,
100-
'github_repository' => Service\GitHubRepositoryFactory::class,
101100
Log\LoggerInterface::class => Service\LoggerFactory::class,
101+
'project_github_repository' => Service\GitHubRepositoryFactory::class,
102102
Service\ErrorHandlingService::class => Service\ErrorHandlingServiceFactory::class,
103103
Service\RepositoryRetriever::class => Service\RepositoryRetrieverFactory::class,
104104
],

module/Application/src/Application/Controller/ContributorsControllerFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ public function createService(ServiceLocatorInterface $controllerManager)
2323
$repositoryRetriever = $serviceManager->get(Service\RepositoryRetriever::class);
2424

2525
/* @var Entity\Repository $repository */
26-
$repository = $serviceManager->get('github_repository');
26+
$repository = $serviceManager->get('project_github_repository');
2727

2828
return new ContributorsController(
2929
$repositoryRetriever,

module/Application/src/Application/Service/GitHubRepositoryFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ class GitHubRepositoryFactory implements FactoryInterface
1414
*/
1515
public function createService(ServiceLocatorInterface $serviceLocator)
1616
{
17-
$config = $serviceLocator->get('Config')['github_repository'];
17+
$config = $serviceLocator->get('Config')['project_github_repository'];
1818

1919
return new Entity\Repository(
2020
$config['owner'],

module/Application/src/Application/View/Helper/GitHubRepositoryUrlFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ public function createService(ServiceLocatorInterface $serviceLocator)
2020
$serviceManager = $serviceLocator->getServiceLocator();
2121

2222
/* @var Entity\Repository $repository */
23-
$repository = $serviceManager->get('github_repository');
23+
$repository = $serviceManager->get('project_github_repository');
2424

2525
return new GitHubRepositoryUrl($repository);
2626
}

module/Application/test/ApplicationTest/Integration/Controller/ContributorsControllerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ public function testContributorsActionCanBeAccessed()
7474
$this->getApplicationServiceLocator()
7575
->setAllowOverride(true)
7676
->setService(
77-
'github_repository',
77+
'project_github_repository',
7878
$repository
7979
)
8080
->setService(

module/Application/test/ApplicationTest/Integration/Service/GitHubRepositoryTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ public function testServiceCanBeRetrieved()
1818

1919
$this->assertInstanceOf(
2020
Entity\Repository::class,
21-
$serviceManager->get('github_repository')
21+
$serviceManager->get('project_github_repository')
2222
);
2323
}
2424
}

0 commit comments

Comments
 (0)