Ejemplo n.º 1
0
 public function __construct($model = 'pages')
 {
     if (empty($this->label)) {
         unset($this->label);
     }
     if (empty($this->template)) {
         unset($this->template);
     }
     parent::__construct($model);
 }
Ejemplo n.º 2
0
 /**
  * The {@link $excerpt} property is unset if it is empty, until it is defined again, the
  * {@link get_excerpt()} getter provides a default value made from the {@link $body}
  * property.
  *
  * @param Model|string $model Defaults to "contents".
  */
 public function __construct($model = 'contents')
 {
     if (empty($this->excerpt)) {
         unset($this->excerpt);
     }
     parent::__construct($model);
 }