public function beforeCreate() { $this->views = new PostsViews(['ipaddress' => $this->getDI()->getShared('request')->getClientAddress()]); }