改名
This commit is contained in:
@@ -228,8 +228,11 @@ abstract class BaseActiveRecord extends Component implements IOrm, ArrayAccess
|
||||
* @throws ReflectionException
|
||||
* @throws Exception
|
||||
*/
|
||||
public static function findOne($param, $db = NULL): static
|
||||
public static function findOne($param, $db = NULL): static|null
|
||||
{
|
||||
if (is_bool($param)) {
|
||||
return null;
|
||||
}
|
||||
if (is_numeric($param)) {
|
||||
$primary = static::getColumns()->getPrimaryKeys();
|
||||
if (empty($primary)) {
|
||||
|
||||
Reference in New Issue
Block a user