/** * {@inheritdoc} */ protected function getEntityIdentifier($object) { $identifier = parent::getEntityIdentifier($object); // create actions does not contain identifier if (!$identifier) { return false; } return $identifier; }
/** * {@inheritDoc} */ public function vote(TokenInterface $token, $object, array $attributes) { $this->object = $object; return parent::vote($token, $object, $attributes); }