/** * [isValid description]. * * @param [type] $key [description] * * @return bool [description] */ public function isValid($key = null) { if (parent::isValid() && $this->getKey()) { return $key && $this->getKey() && $this->chiper->decrypt($this->getKey()) == $this->chiper->decrypt($key); } return false; }
/** * [isValid description]. * * @param [type] $key [description] * * @return bool [description] */ public function isValid($key = null) { if (parent::isValid()) { if ($key && parent::getKey() && parent::getKey() == $key) { return true; } } return false; }