diff --git a/Database/Base/BaseActiveRecord.php b/Database/Base/BaseActiveRecord.php index 871b8627..9ea32f69 100644 --- a/Database/Base/BaseActiveRecord.php +++ b/Database/Base/BaseActiveRecord.php @@ -193,11 +193,13 @@ abstract class BaseActiveRecord extends Component implements IOrm, \ArrayAccess /** * @param $param - * @param $db - * @return $this - * @throws + * @param null $db + * @return static + * @throws NotFindClassException + * @throws ReflectionException + * @throws Exception */ - public static function findOne($param, $db = NULL): static + public static function findOne($param, $db = NULL): mixed { if (is_numeric($param)) { $primary = static::getColumns()->getPrimaryKeys(); diff --git a/Database/IOrm.php b/Database/IOrm.php index 2bb2a3fb..4e3d9a5a 100644 --- a/Database/IOrm.php +++ b/Database/IOrm.php @@ -21,7 +21,7 @@ interface IOrm * @param null $db * @return ActiveRecord */ - public static function findOne($param, $db = NULL): static; + public static function findOne($param, $db = NULL): mixed; /**