Release of v3.2.4-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:
2024-08-21 21:34:32 +02:00
parent 4bed7a52da
commit 3ca5548481
11 changed files with 56 additions and 33 deletions

View File

@ -308,10 +308,10 @@ class ComponentbuilderModelCompiler 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();
@ -334,9 +334,8 @@ class ComponentbuilderModelCompiler extends ListModel
$db->setQuery($query);
// return the result
return $db->loadObjectList();
return $db->loadObjectList() ?? null;
}
/**
* Get all dynamic content

View File

@ -1125,7 +1125,7 @@ class ComponentbuilderModelLibrary extends AdminModel
// also check to insure these names are not used again
if (!isset(ComponentbuilderHelper::$libraryNames[$data['id']]) && in_array($data['name'], ComponentbuilderHelper::$libraryNames))
{
$data['name'] = $this->generateUniqe('name', $data['name']);
$data['name'] = $this->generateUnique('name', $data['name']);
}
// Set the Params Items to data

View File

@ -220,10 +220,10 @@ class ComponentbuilderModelSearch extends ItemModel
/**
* 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();
@ -246,7 +246,6 @@ class ComponentbuilderModelSearch extends ItemModel
$db->setQuery($query);
// return the result
return $db->loadObjectList();
}
return $db->loadObjectList() ?? null;
}
}