Closed Tigrov closed 1 month ago
Looks like a legacy from the old version where behaviors were built in.
Currently, an exception will only be thrown if the relation query is not realized or is realized with an error. In this case, there is no need to suppress the error.
https://github.com/yiisoft/active-record/blob/a4816d0ee20c86531413f52e47bfd1d831ac3a04/src/ActiveRecordInterface.php#L222
After changes:
public function relationQuery(string $name): ActiveQueryInterface;
Looks like a legacy from the old version where behaviors were built in.
Currently, an exception will only be thrown if the relation query is not realized or is realized with an error. In this case, there is no need to suppress the error.
https://github.com/yiisoft/active-record/blob/a4816d0ee20c86531413f52e47bfd1d831ac3a04/src/ActiveRecordInterface.php#L222
After changes: