MDL-81634 core: Fix all implicitly defined nullables

Note: This does not impact third-party libraries.
This commit is contained in:
Andrew Nicols
2024-08-02 14:11:12 +08:00
parent 8a6e8563fd
commit 024e36be17
391 changed files with 782 additions and 782 deletions
+2 -2
View File
@@ -49,7 +49,7 @@ abstract class persistent {
* @param int $id If set, this is the id of an existing record, used to load the data.
* @param stdClass $record If set will be passed to {@link self::from_record()}.
*/
public function __construct($id = 0, stdClass $record = null) {
public function __construct($id = 0, ?stdClass $record = null) {
global $CFG;
if ($id > 0) {
@@ -975,7 +975,7 @@ abstract class persistent {
* @param array $params
* @return bool
*/
public static function record_exists_select($select, array $params = null) {
public static function record_exists_select($select, ?array $params = null) {
global $DB;
return $DB->record_exists_select(static::TABLE, $select, $params);
}