public function laststoragesync() { $this->allowMethods(array('GET', 'POST')); // Deprecated after 3.0, which used auth=1 if ($this->apiVersion < 2 || !empty($_GET['auth'])) { $lastSync = Zotero_Users::getLastStorageSync($this->objectUserID); } else { $lastSync = Zotero_Libraries::getLastStorageSync($this->objectLibraryID); } if (!$lastSync) { $this->e404(); } echo $lastSync; exit; }
public function laststoragesync() { if (!$this->httpAuth && !$this->permissions->isSuper()) { $this->e403(); } $this->allowMethods(array('GET', 'POST')); if ($this->method == 'POST') { //Zotero_Users::setLastStorageSync($this->userID); } // Deprecated after 3.0, which used auth=1 if ($this->apiVersion < 2 || !empty($_GET['auth'])) { $lastSync = Zotero_Users::getLastStorageSync($this->objectUserID); } else { $lastSync = Zotero_Libraries::getLastStorageSync($this->objectLibraryID); } if (!$lastSync) { $this->e404(); } echo $lastSync; exit; }
public function laststoragesync() { if (!$this->httpAuth) { $this->e403(); } $this->allowMethods(array('GET', 'POST')); if ($this->method == 'POST') { //Zotero_Users::setLastStorageSync($this->userID); } $lastSync = Zotero_Users::getLastStorageSync($this->userID); if (!$lastSync) { $this->e404(); } echo $lastSync; exit; }