Repository navigation
Conversation
Korbeil
force-pushed
the
afup-migration-entite-ting-badge
branch
from
September 21, 2026 19:15
5f9fb14 to
2e9aa3a
Compare
Korbeil
marked this pull request as ready for review
September 21, 2026 19:20
Korbeil
force-pushed
the
afup-migration-entite-ting-badge
branch
from
October 5, 2026 19:31
2e9aa3a to
b18128c
Compare
Korbeil
force-pushed
the
afup-migration-entite-ting-badge
branch
from
October 6, 2026 08:34
b18128c to
a2d4f9d
Compare
Le referer peut être null; RedirectResponse attend une string. On retombe sur l'URI courante (pattern déjà utilisé dans PrepareAction). Cela corrige l'erreur PHPStan argument.type et retire les entrées de baseline devenues inutiles pour UserBadgeNewAction et UserBadgeDeleteAction.
stakovicz
reviewed
Oct 11, 2026
| } | ||
|
|
||
| public function loadByBadge(Badge $badge) | ||
| public function loadByBadge(int $badgeId) |
Contributor
There was a problem hiding this comment.
**question : ** pourquoi changer ce typage ?
|
|
||
| if (!is_numeric($badgeId) || !is_numeric($userId)) { | ||
| throw new \RuntimeException('Identifiants de badge invalides.'); | ||
| $badgeId = (int) $request->attributes->get('badgeId'); |
Contributor
There was a problem hiding this comment.
Suggested change
| $badgeId = (int) $request->attributes->get('badgeId'); | |
| $badgeId = $request->attributes->getInt('badgeId'); |
| 'badgeId' => (int) $badgeId, | ||
| 'userId' => (int) $userId, | ||
| $userBadge = $this->userBadgeRepository->findOneBy([ | ||
| 'userId' => (int) $request->attributes->get('userId'), |
Contributor
There was a problem hiding this comment.
Suggested change
| 'userId' => (int) $request->attributes->get('userId'), | |
| 'userId' => $request->attributes->getInt('userId'), |
| ]); | ||
| if ($userBadge !== null) { | ||
| $this->userBadgeRepository->delete($userBadge); | ||
| if (null === $userBadge) { |
Contributor
There was a problem hiding this comment.
suggestion : tester l'instanceOf, c'est plus robuste.
Korbeil
marked this pull request as draft
October 11, 2026 19:45
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Migre les badges des membres (tables
afup_badgeetafup_personnes_physiques_badge) de Ting vers Doctrine ORM, dans la continuité du chantier de migration #2383 et du pattern établi par la PR #2387. Le comportement fonctionnel est inchangé et aucune migration de schéma n'est nécessaire.Changes
How to test
make test-integration-ci(inclut les nouveaux tests) puismake phpstan.