Release of v5.0.3-alpha2
Fix library save as copy error. #1162. Fix the error when no components exists. #1164. Fix search page error due to File class.
This commit is contained in:
@@ -445,10 +445,10 @@ class CompilerModel extends ListModel
|
||||
/**
|
||||
* Get all components in the system
|
||||
*
|
||||
* @return array
|
||||
* @return array|null
|
||||
* @since 3.2.0
|
||||
**/
|
||||
public function getComponents(): array
|
||||
public function getComponents(): ?array
|
||||
{
|
||||
// Get a db connection.
|
||||
$db = $this->getDbo();
|
||||
@@ -471,9 +471,8 @@ class CompilerModel extends ListModel
|
||||
$db->setQuery($query);
|
||||
|
||||
// return the result
|
||||
return $db->loadObjectList();
|
||||
return $db->loadObjectList() ?? null;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get all dynamic content
|
||||
|
Reference in New Issue
Block a user