We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4dd757a commit a83d3e3Copy full SHA for a83d3e3
src/ScopeAsSelect.php
@@ -74,7 +74,7 @@ public static function addMacro(string $name = 'addScopeAsSelect')
74
// Query the model and explicitly set the targetted table, as the model's table
75
// is just the aliased table with the 'as' statement.
76
$subSelect = $aliasedModel::query();
77
- $subSelect->getQuery()->from("{$originalTable} as {$aliasedTable}");
+ $subSelect->getQuery()->from($originalTable, $aliasedTable);
78
79
// Apply the where constraint based on the model's key name and apply the $callable.
80
$subSelect
0 commit comments