MDL-81634 core: Fix all implicitly defined nullables
Note: This does not impact third-party libraries.
This commit is contained in:
@@ -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);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user