Skip to content

Commit

Permalink
Merge branch '1.1' into 1.2
Browse files Browse the repository at this point in the history
* 1.1:
  Added title to product reviews, fixed #9425
  Fix tests.
  Make tests passing again
  Apply coding standard fixes
  Random PHPStan fixed (level 2)
  Install Doctrine extension for PHPStan
  Install Symfony extension for PHPStan
  Fix constraint class related ambiguities in validators
  Install PHPStan 0.10 & Webmozart/Assert extension
  Fix DoctrineTargetEntitiesResolverPass priority to avoid mapping issues.
  • Loading branch information
pamil committed Jul 3, 2018
2 parents ffa9143 + 4007f89 commit 26db2d5
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
5 changes: 4 additions & 1 deletion Controller/FlashHelper.php
Expand Up @@ -16,6 +16,7 @@
use Doctrine\Common\Inflector\Inflector;
use Sylius\Bundle\ResourceBundle\Event\ResourceControllerEvent;
use Sylius\Component\Resource\Model\ResourceInterface;
use Symfony\Component\HttpFoundation\Session\Flash\FlashBagInterface;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
use Symfony\Component\Translation\TranslatorBagInterface;
use Symfony\Component\Translation\TranslatorInterface;
Expand Down Expand Up @@ -122,7 +123,9 @@ private function addFlash(string $type, string $message, array $parameters = [])
$message = $this->prepareMessage($message, $parameters);
}

$this->session->getBag('flashes')->add($type, $message);
/** @var FlashBagInterface $flashBag */
$flashBag = $this->session->getBag('flashes');
$flashBag->add($type, $message);
}

/**
Expand Down
2 changes: 1 addition & 1 deletion Controller/RequestConfiguration.php
Expand Up @@ -154,7 +154,7 @@ public function getFormOptions()
}

/**
* @param $name
* @param string $name
*
* @return string
*/
Expand Down
3 changes: 2 additions & 1 deletion SyliusResourceBundle.php
Expand Up @@ -18,6 +18,7 @@
use Sylius\Bundle\ResourceBundle\DependencyInjection\Compiler\RegisterResourceRepositoryPass;
use Sylius\Bundle\ResourceBundle\DependencyInjection\Compiler\RegisterResourcesPass;
use Sylius\Bundle\ResourceBundle\DependencyInjection\Compiler\WinzouStateMachinePass;
use Symfony\Component\DependencyInjection\Compiler\PassConfig;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\HttpKernel\Bundle\Bundle;

Expand All @@ -35,7 +36,7 @@ public function build(ContainerBuilder $container): void
parent::build($container);

$container->addCompilerPass(new RegisterResourcesPass());
$container->addCompilerPass(new DoctrineTargetEntitiesResolverPass());
$container->addCompilerPass(new DoctrineTargetEntitiesResolverPass(), PassConfig::TYPE_BEFORE_OPTIMIZATION, 1);
$container->addCompilerPass(new RegisterResourceRepositoryPass());
$container->addCompilerPass(new RegisterFormBuilderPass());
$container->addCompilerPass(new WinzouStateMachinePass());
Expand Down
2 changes: 1 addition & 1 deletion test/app/AppKernel.php
Expand Up @@ -34,10 +34,10 @@ public function registerBundles()
new Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
new FOS\RestBundle\FOSRestBundle(),
new JMS\SerializerBundle\JMSSerializerBundle(),
new Doctrine\Bundle\DoctrineBundle\DoctrineBundle(),
new Sylius\Bundle\ResourceBundle\SyliusResourceBundle(),
new WhiteOctober\PagerfantaBundle\WhiteOctoberPagerfantaBundle(),
new Bazinga\Bundle\HateoasBundle\BazingaHateoasBundle(),
new Doctrine\Bundle\DoctrineBundle\DoctrineBundle(),
new Symfony\Bundle\TwigBundle\TwigBundle(),
new \winzou\Bundle\StateMachineBundle\winzouStateMachineBundle(),
new Fidry\AliceDataFixtures\Bridge\Symfony\FidryAliceDataFixturesBundle(),
Expand Down

0 comments on commit 26db2d5

Please sign in to comment.