fix: fix php cs errors

This commit is contained in:
Léa BAR 2026-04-30 14:50:12 +02:00
parent 52d7f2b3b9
commit a5d9bbf45f
No known key found for this signature in database
GPG key ID: 537DA1EC6CA7571D
8 changed files with 19 additions and 22 deletions

View file

@ -103,8 +103,7 @@ final class ProductController extends AbstractController
}
return $this->render('pages/product/show.html.twig', compact('slug', 'id', 'product'));
} else {
throw new GoneHttpException();
}
throw new GoneHttpException();
}
}

View file

@ -69,9 +69,8 @@ final class ServiceController extends AbstractController
}
return $this->render('pages/product/new_service.html.twig', compact('form', 'product'));
} else {
throw new GoneHttpException();
}
throw new GoneHttpException();
}
#[Route([
@ -96,8 +95,7 @@ final class ServiceController extends AbstractController
}
return $this->render('pages/product/edit_service.html.twig', compact('form', 'product'));
} else {
throw new GoneHttpException();
}
throw new GoneHttpException();
}
}

View file

@ -94,8 +94,7 @@ final class UserProductsController extends AbstractController
if ($this->configurationRepository->getServicesParameter()) {
return $this->render('pages/account/product/list.html.twig', compact('pagination', 'form'));
} else {
throw new GoneHttpException('there is no services');
}
throw new GoneHttpException('there is no services');
}
}

View file

@ -80,16 +80,16 @@ final class PayumManager
'groupOfferId' => (string) $offer->getId(),
],
];
} else {
return [
// method must be set as the default value is not retrieved from the gateway configuration
'method' => PaymentMethod::CREDITCARD->value,
'metadata' => [
'platformId' => (string) $offer->getConfiguration()?->getId(),
'platformOfferId' => (string) $offer->getId(),
],
];
}
return [
// method must be set as the default value is not retrieved from the gateway configuration
'method' => PaymentMethod::CREDITCARD->value,
'metadata' => [
'platformId' => (string) $offer->getConfiguration()?->getId(),
'platformOfferId' => (string) $offer->getId(),
],
];
}
/**

View file

@ -12,6 +12,7 @@ use Doctrine\ORM\QueryBuilder;
use Gedmo\Sortable\Entity\Repository\SortableRepository;
/**
* @extends SortableRepository<MenuItem>
* @method MenuItem|null find($id, $lockMode = null, $lockVersion = null)
* @method MenuItem|null findOneBy(array $criteria, array $orderBy = null)
* @method MenuItem[] findAll()

View file

@ -15,7 +15,7 @@ use App\Repository\GroupRepository;
final class GroupGetStatsProvider implements ProviderInterface
{
public function __construct(
readonly private GroupRepository $groupRepository,
private readonly GroupRepository $groupRepository,
) {
}

View file

@ -16,8 +16,8 @@ use App\Repository\UserRepository;
class GroupsProvider implements ProviderInterface
{
public function __construct(
readonly private GroupRepository $groupRepository,
readonly private UserRepository $userRepository,
private readonly GroupRepository $groupRepository,
private readonly UserRepository $userRepository,
) {
}

View file

@ -6,14 +6,14 @@ namespace App\Tests\Unit\Notifier;
use App\Entity\User;
use App\Notifier\SmsNotifier;
use Monolog\Test\TestCase;
use Monolog\Test\MonologTestCase;
use PHPUnit\Framework\MockObject\MockObject;
use Psr\Log\LoggerInterface;
use Symfony\Component\HttpClient\Response\MockResponse;
use Symfony\Component\Notifier\Exception\TransportException;
use Symfony\Component\Notifier\TexterInterface;
final class SmsNotifierTest extends TestCase
final class SmsNotifierTest extends MonologTestCase
{
public function testNotify(): void
{