From 32d09a23535f742fb6500020d36211d085147398 Mon Sep 17 00:00:00 2001 From: fbsanchez Date: Thu, 7 Jan 2021 18:24:51 +0100 Subject: [PATCH] added name method alias of nombre to Group class --- pandora_console/include/lib/Group.php | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/pandora_console/include/lib/Group.php b/pandora_console/include/lib/Group.php index fc9615cfce..3bd6585344 100644 --- a/pandora_console/include/lib/Group.php +++ b/pandora_console/include/lib/Group.php @@ -105,6 +105,23 @@ class Group extends Entity } + /** + * Alias of 'nombre'. + * + * @param string|null $name Name of group. + * + * @return string|void Name assigned or void if set operation. + */ + public function name(?string $name=null) + { + if ($name === null) { + return $this->nombre(); + } + + return $this->nombre($name); + } + + /** * Retrieves a list of groups fitered. *