Beispiel #1
0
 /**
  * Unlocks a uri
  *
  * This method removes a lock from a uri. It is assumed all the supplied information is correct and verified
  *
  * @param string $uri
  * @param Sabre_DAV_Locks_LockInfo $lockInfo
  * @return bool
  */
 public function unlockNode($uri, Sabre_DAV_Locks_LockInfo $lockInfo)
 {
     if (!$this->server->broadcastEvent('beforeUnlock', array($uri, $lockInfo))) {
         return;
     }
     if ($this->locksBackend) {
         return $this->locksBackend->unlock($uri, $lockInfo);
     }
 }
Beispiel #2
0
 /**
  * Unlocks a uri
  *
  * This method removes a lock from a uri. It is assumed all the supplied information is correct and verified
  * 
  * @param string $uri 
  * @param Sabre_DAV_Locks_LockInfo $lockInfo 
  * @return void
  */
 public function unlockNode($uri, Sabre_DAV_Locks_LockInfo $lockInfo)
 {
     if (!$this->server->broadcastEvent('beforeUnlock', array($uri, $lockInfo))) {
         return;
     }
     try {
         $node = $this->server->tree->getNodeForPath($uri);
         if ($node instanceof Sabre_DAV_ILockable) {
             return $node->unlock($lockInfo);
         }
     } catch (Sabre_DAV_Exception_FileNotFound $e) {
         // In case the node didn't exist, this could be a lock-null request
     }
     if ($this->locksBackend) {
         return $this->locksBackend->unlock($uri, $lockInfo);
     }
 }