Skip to content

Commit

Permalink
compatibility with 176 added
Browse files Browse the repository at this point in the history
  • Loading branch information
GytisZum committed Dec 17, 2024
1 parent f756360 commit 8d5055d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
6 changes: 4 additions & 2 deletions config/services.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,11 +102,13 @@ services:
- 'SubscriptionOptions'

Mollie\Subscription\Controller\Symfony\SubscriptionFAQController:
class: Mollie\Subscription\Controller\Symfony\SubscriptionFAQController
public: true
autowire: true
autoconfigure: true
autowire: true # Optional, but useful for dependency injection

Mollie\Subscription\Controller\Symfony\SubscriptionController:
class: Mollie\Subscription\Controller\Symfony\SubscriptionController
public: true
autowire: true
autoconfigure: true
autoconfigure: true
7 changes: 5 additions & 2 deletions subscription/Form/Options/SubscriptionOptionsType.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
use PrestaShopBundle\Form\Admin\Type\TranslatorAwareType;
use Symfony\Component\Form\Extension\Core\Type\ChoiceType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Contracts\Translation\TranslatorInterface;
use Symfony\Contracts\Translation\TranslatorInterface as NewTranslatorInterface; // Newer Symfony translator
use Symfony\Component\Translation\TranslatorInterface as OldTranslatorInterface; // Older Symfony translator

if (!defined('_PS_VERSION_')) {
exit;
Expand All @@ -30,9 +31,11 @@ class SubscriptionOptionsType extends TranslatorAwareType
private $carrierOptionProvider;
/** @var Module */
private $module;
/** @var NewTranslatorInterface | OldTranslatorInterface */
private $translator;

Check failure on line 35 in subscription/Form/Options/SubscriptionOptionsType.php

View workflow job for this annotation

GitHub Actions / PHPStan (1.7.6.8)

Property Mollie\Subscription\Form\Options\SubscriptionOptionsType::$translator has unknown class Symfony\Contracts\Translation\TranslatorInterface as its type.

Check failure on line 35 in subscription/Form/Options/SubscriptionOptionsType.php

View workflow job for this annotation

GitHub Actions / PHPStan (1.7.7.0)

Property Mollie\Subscription\Form\Options\SubscriptionOptionsType::$translator has unknown class Symfony\Contracts\Translation\TranslatorInterface as its type.

public function __construct(
TranslatorInterface $translator,
$translator,
array $locales,
FormChoiceProviderInterface $carrierOptionProvider,
Module $module
Expand Down

0 comments on commit 8d5055d

Please sign in to comment.