From 35c8729b862158596a20d2fd22d9a122b4a0a7b5 Mon Sep 17 00:00:00 2001 From: Tom Wright Date: Fri, 26 Apr 2024 14:19:38 +0000 Subject: [PATCH] Upgraded Doctrine to ORM 3 and DBAL 4 Signed-off-by: Tom Wright --- CHANGELOG.md | 1 + composer.json | 6 +++--- src/Indoctrination/Generator/Uuid.php | 11 ++++------- 3 files changed, 8 insertions(+), 10 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b6fa45e..b9ffdf4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,4 @@ +* Upgraded Doctrine to ORM 3 and DBAL 4 * Updated dependency list ## v0.1.3 (2024-04-24) diff --git a/composer.json b/composer.json index ea42e12..0766acc 100644 --- a/composer.json +++ b/composer.json @@ -18,8 +18,8 @@ "decodelabs/stash": "^0.5.0", "decodelabs/veneer": "^0.10.24", - "doctrine/orm": "^2.17", - "doctrine/dbal": "^3.7", + "doctrine/orm": "^3", + "doctrine/dbal": "^4", "doctrine/migrations": "^3.7" }, "require-dev": { @@ -51,7 +51,7 @@ }, "extra": { "branch-alias": { - "dev-develop": "0.1.x-dev" + "dev-develop": "0.2.x-dev" } } } diff --git a/src/Indoctrination/Generator/Uuid.php b/src/Indoctrination/Generator/Uuid.php index faa98e9..7384c8b 100644 --- a/src/Indoctrination/Generator/Uuid.php +++ b/src/Indoctrination/Generator/Uuid.php @@ -10,17 +10,14 @@ namespace DecodeLabs\Indoctrination\Generator; use DecodeLabs\Guidance; -use Doctrine\ORM\EntityManager; +use Doctrine\ORM\EntityManagerInterface; use Doctrine\ORM\Id\AbstractIdGenerator; class Uuid extends AbstractIdGenerator { - /** - * @param object $entity - */ - public function generate( - EntityManager $entityManager, - $entity + public function generateId( + EntityManagerInterface $entityManager, + ?object $entity ): string { return (string)Guidance::createV7(); }