Fix code doc issues

This commit is contained in:
Matt Sherman 2023-08-25 14:34:14 -04:00
parent 530e4f05ed
commit a22d8d895c
1 changed files with 6 additions and 3 deletions

View File

@ -18,6 +18,8 @@ final class BlockTemplateRegistry {
/**
* Templates.
*
* @var array
*/
protected $templates = array();
@ -35,8 +37,9 @@ final class BlockTemplateRegistry {
/**
* Register a single template.
*
* @param string $id Template ID.
* @param array $template Template layout.
* @param BlockTemplateInterface $template Template to register.
*
* @throws \ValueError If a template with the same ID already exists.
*/
public function register( BlockTemplateInterface $template ) {
$id = $template->get_id();
@ -58,7 +61,7 @@ final class BlockTemplateRegistry {
/**
* Get a single registered template.
*
* @param string $id ID of the template
* @param string $id ID of the template.
*/
public function get_registered( $id ): BlockTemplateInterface {
return isset( $this->templates[ $id ] ) ? $this->templates[ $id ] : null;