/** * Checks rights to update (content) current object. * @param SecurityContext $securityContext Security context. * @return bool */ public function canUpdate(SecurityContext $securityContext) { return $securityContext->canUpdate($this->realObjectId); }
/** * Checks rights to update current object by cloud import. * @param SecurityContext $securityContext Security context. * @return bool */ public function canUpdateByCloudImport(SecurityContext $securityContext) { return $this->getContentProvider() && $this->getCreatedBy() == $securityContext->getUserId() && $securityContext->canUpdate($this->id); }