示例#1
0
 public function clear()
 {
     $this->sessionCheck();
     if (Zotero_Sync::userIsReadLocked($this->userID) || Zotero_Sync::userIsWriteLocked($this->userID)) {
         $message = "You cannot reset server data while one of your libraries " . "is locked for syncing. Please wait for all related syncs to complete.";
         $this->error(400, 'SYNC_LOCKED', $message);
     }
     StatsD::increment("sync.clear");
     Zotero_Users::clearAllData($this->userID);
     $this->responseXML->addChild('cleared');
     $this->end();
 }