Skip to content

Commit

Permalink
Rename method from getType to getFlags
Browse files Browse the repository at this point in the history
  • Loading branch information
msmakouz committed Feb 8, 2024
1 parent 792de93 commit feb91a2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Annotation/Generated.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public function __construct(
) {
}

public function getType(): ?int
public function getFlags(): ?int
{
if (!$this->beforeInsert && !$this->onInsert && !$this->beforeUpdate) {
return null;

Check warning on line 29 in src/Annotation/Generated.php

View check run for this annotation

Codecov / codecov/patch

src/Annotation/Generated.php#L29

Added line #L29 was not covered by tests
Expand Down
2 changes: 1 addition & 1 deletion src/Configurator.php
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ public function initGeneratedFields(EntitySchema $entity, \ReflectionClass $clas
try {
$generated = $this->reader->firstPropertyMetadata($property, Generated::class);
if ($generated !== null) {
$entity->getFields()->get($property->getName())->setGenerated($generated->getType());
$entity->getFields()->get($property->getName())->setGenerated($generated->getFlags());
}
} catch (\Throwable $e) {
throw new AnnotationException($e->getMessage(), (int) $e->getCode(), $e);

Check warning on line 314 in src/Configurator.php

View check run for this annotation

Codecov / codecov/patch

src/Configurator.php#L313-L314

Added lines #L313 - L314 were not covered by tests
Expand Down

0 comments on commit feb91a2

Please sign in to comment.