/** * Unlock object for comments * * @param void * @return null */ function unlock() { if (!$this->active_object->can_have_comments) { $this->httpError(HTTP_ERR_NOT_FOUND, null, true, $this->request->isApiCall()); } // if if (!$this->active_object->canChangeLockedState($this->logged_user)) { $this->httpError(HTTP_ERR_FORBIDDEN, null, true, $this->request->isApiCall()); } // if $this->executeOnActiveObject('unlock', array($this->logged_user), lang(':type ":name" has been unlocked', array('type' => $this->active_object->getVerboseType(), 'name' => $this->active_object->getName())), lang('Failed to unlock :type ":name"', array('type' => $this->active_object->getVerboseType(true), 'name' => $this->active_object->getName()))); }