Skip to content

Commit

Permalink
Merge pull request #698 from ausi/fix/doctrine-3-comparator
Browse files Browse the repository at this point in the history
Restore compatibility with Doctrine DBAL version 3
  • Loading branch information
Spomky authored Mar 8, 2025
2 parents a5f3223 + a63146a commit 7ef33c3
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 21 deletions.
9 changes: 2 additions & 7 deletions src/symfony/src/Doctrine/Type/AttestedCredentialDataType.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
namespace Webauthn\Bundle\Doctrine\Type;

use Doctrine\DBAL\Platforms\AbstractPlatform;
use Doctrine\DBAL\Types\Type;
use Doctrine\DBAL\Types\JsonType;
use Webauthn\AttestedCredentialData;

final class AttestedCredentialDataType extends Type
final class AttestedCredentialDataType extends JsonType
{
use SerializerTrait;

Expand All @@ -30,11 +30,6 @@ public function convertToPHPValue($value, AbstractPlatform $platform): ?Attested
return $this->deserialize($value, AttestedCredentialData::class);
}

public function getSQLDeclaration(array $column, AbstractPlatform $platform): string
{
return $platform->getJsonTypeDeclarationSQL($column);
}

public function getName(): string
{
return 'attested_credential_data';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
namespace Webauthn\Bundle\Doctrine\Type;

use Doctrine\DBAL\Platforms\AbstractPlatform;
use Doctrine\DBAL\Types\Type;
use Doctrine\DBAL\Types\JsonType;
use Webauthn\PublicKeyCredentialDescriptor;

final class PublicKeyCredentialDescriptorType extends Type
final class PublicKeyCredentialDescriptorType extends JsonType
{
use SerializerTrait;

Expand All @@ -30,11 +30,6 @@ public function convertToPHPValue($value, AbstractPlatform $platform): ?PublicKe
return $this->deserialize($value, PublicKeyCredentialDescriptor::class);
}

public function getSQLDeclaration(array $column, AbstractPlatform $platform): string
{
return $platform->getJsonTypeDeclarationSQL($column);
}

public function getName(): string
{
return 'public_key_credential_descriptor';
Expand Down
9 changes: 2 additions & 7 deletions src/symfony/src/Doctrine/Type/TrustPathDataType.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
namespace Webauthn\Bundle\Doctrine\Type;

use Doctrine\DBAL\Platforms\AbstractPlatform;
use Doctrine\DBAL\Types\Type;
use Doctrine\DBAL\Types\JsonType;
use Webauthn\TrustPath\TrustPath;

final class TrustPathDataType extends Type
final class TrustPathDataType extends JsonType
{
use SerializerTrait;

Expand All @@ -30,11 +30,6 @@ public function convertToPHPValue($value, AbstractPlatform $platform): ?TrustPat
return $this->deserialize($value, TrustPath::class);
}

public function getSQLDeclaration(array $column, AbstractPlatform $platform): string
{
return $platform->getJsonTypeDeclarationSQL($column);
}

public function getName(): string
{
return 'trust_path';
Expand Down

0 comments on commit 7ef33c3

Please # to comment.