示例#1
0
 /**
  * Unsubscribe from all threads.
  * @param string $token
  * @return html
  */
 private function onUnSubscribeExtAll($token)
 {
     if (false === $this->checkExternalToken($token)) {
         return $this->module->error('err_token');
     }
     if (false === GWF_ForumSubscription::unsubscribeAll($this->user->getID())) {
         return GWF_HTML::err('ERR_DATABASE', array(__FILE__, __LINE__));
     }
     if (false === $this->options->saveSubscription(GWF_ForumOptions::SUBSCRIBE_NONE)) {
         return GWF_HTML::err('ERR_DATABASE', array(__FILE__, __LINE__));
     }
     return $this->module->message('msg_unsub_all', array(GWF_WEB_ROOT . 'forum'));
 }