aboutsummaryrefslogtreecommitdiff
path: root/app/class/Route.php
diff options
context:
space:
mode:
authorvincent-peugnet <v.peugnet@free.fr>2020-01-29 02:34:50 +0100
committervincent-peugnet <v.peugnet@free.fr>2020-01-29 02:34:50 +0100
commit64ac1605b6fe8e997134dd57cc30f30b99ebc076 (patch)
treed4fd89c68f0f0eb7b49ea92336f8f8ab5f778e45 /app/class/Route.php
parentb6173772bdef1eaf067573373ab500d67dfc454d (diff)
downloadwcms-64ac1605b6fe8e997134dd57cc30f30b99ebc076.tar.gz
wcms-64ac1605b6fe8e997134dd57cc30f30b99ebc076.zip
refactor : item abstract class
new Item abstract class with hydrate and dry functions to clean others
Diffstat (limited to 'app/class/Route.php')
-rw-r--r--app/class/Route.php12
1 files changed, 1 insertions, 11 deletions
diff --git a/app/class/Route.php b/app/class/Route.php
index 4f2a6de..32dfaf5 100644
--- a/app/class/Route.php
+++ b/app/class/Route.php
@@ -2,7 +2,7 @@
namespace Wcms;
-class Route
+class Route extends Item
{
protected $id = null;
protected $aff = null;
@@ -16,16 +16,6 @@ class Route
$this->hydrate($vars);
}
- public function hydrate($vars)
- {
- foreach ($vars as $var => $value) {
- $method = 'set' . $var;
- if (method_exists($this, $method)) {
- $this->$method($value);
- }
- }
- }
-
public function toarray()
{
$array = [];