public function getObject()
 {
     $result = parent::getObject();
     if (!$this->acl->isAllowed($this->getCurrentMemberId(), null, $this->options['privilege'])) {
         throw new sfError404Exception('You are not allowed access to this resource.');
     }
     return $result;
 }
 public function getObject()
 {
     $result = parent::getObject();
     if ($result instanceof opAccessControlRecordInterface) {
         if (!$result->isAllowed($this->getCurrentMember(), $this->options['privilege'])) {
             $this->handleRestriction();
         }
     } elseif (!$this->acl->isAllowed($this->getCurrentMemberId(), null, $this->options['privilege'])) {
         $this->handleRestriction();
     }
     return $result;
 }