public function testForErrors()
 {
     if (!$this->object->getVersionID()) {
         $c = Page::getByID($this->object->getCollectionID());
         $cp = new Permissions($c);
         if ($cp->canViewPageVersions()) {
             return COLLECTION_FORBIDDEN;
         } else {
             return COLLECTION_NOT_FOUND;
         }
     } elseif (!$this->object->isMostRecent()) {
         return VERSION_NOT_RECENT;
     }
     return parent::testForErrors();
 }
Esempio n. 2
0
 public function getCollectionID()
 {
     return parent::getCollectionID();
 }