Skip to content

Commit fd70a2e

Browse files
committed
Usage of Fusion method to solve relations names
1 parent 8310e2c commit fd70a2e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/SQL/SolverColumn.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Simples\Persistence\SQL;
44

55
use Simples\Persistence\Field;
6+
use Simples\Persistence\Fusion;
67
use Simples\Persistence\SQL\Error\SimplesUnsupportedField;
78

89
/**
@@ -50,7 +51,7 @@ private function parseColumnField(Field $column): string
5051
{
5152
$collection = $column->getCollection();
5253
if ($column->hasFrom()) {
53-
$collection = '__' . strtoupper($column->getFrom()->getName()) . '__';
54+
$collection = Fusion::relation($column->getFrom()->getName());
5455
}
5556
$name = $column->getName();
5657
$options = $column->getOptions();

0 commit comments

Comments
 (0)