Skip to content

Commit

Permalink
WIP: Sf4 Compat
Browse files Browse the repository at this point in the history
  • Loading branch information
BadPixxel committed Dec 5, 2020
1 parent 78ff864 commit 9f00d84
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/Models/Traits/AccessTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public function setService(string $service) : self
*/
public function getService() : string
{
return $this->service;
return strtolower($this->service);
}

/**
Expand Down
6 changes: 1 addition & 5 deletions src/Resources/config/services.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,4 @@ services:
arguments:
- "@splash.widgets.factory"
- "@=service('doctrine.orm.entity_manager').getRepository('SplashWidgetsBundle:WidgetCollection')"
- "@service_container"




- "@service_container"
4 changes: 2 additions & 2 deletions src/Services/ManagerService.php
Original file line number Diff line number Diff line change
Expand Up @@ -135,10 +135,10 @@ public function connect(string $service) : bool
{
//==============================================================================
// Link to Widget Interface Service if Available
if (!$service || !$this->container->has($service)) {
if (!$service || !$this->container->has(strtolower($service))) {
return false;
}
$sfService = $this->container->get($service);
$sfService = $this->container->get(strtolower($service));
if (!($sfService instanceof WidgetProviderInterface)) {
$msg = "Widget Service Provider must Implement (".WidgetProviderInterface::class.")";

Expand Down

0 comments on commit 9f00d84

Please sign in to comment.