Skip to content

Commit

Permalink
[ENH] support ‘__self’ keyword for columns
Browse files Browse the repository at this point in the history
  • Loading branch information
n3o77 committed Feb 25, 2024
1 parent b46cd39 commit ac92e05
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/ColumnType/AbstractColumnType.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,10 @@ public function configureOptions(OptionsResolver $resolver): void

public function getValue(string $field, object $object, array $options = [])
{
if ('__self' === $field) {
return $object;
}

if ($options['isMapped']) {
try {
if ($options['resolve_collections']) {
Expand Down

0 comments on commit ac92e05

Please sign in to comment.