/**
  * Add our new tag to the array of existing tags.
  *
  * @param array &$tags
  * @return bool
  */
 public static function registerChangeTags(array &$tags)
 {
     $tags[] = MarkMajorChanges::getMainTagName();
     $tags[] = MarkMajorChanges::getSecondaryTagName();
     return true;
 }
 protected function limitByMode($mode)
 {
     if ($mode === 'onlymajor') {
         $tag = MarkMajorChanges::getMainTagName();
     } elseif ($mode === 'onlyminor') {
         $tag = MarkMajorChanges::getSecondaryTagName();
     } else {
         return array();
     }
     return array('ls_field' => 'Tag', 'ls_value' => $tag);
 }
 protected function saveTags()
 {
     $revId = $this->getTitle()->getLatestRevID();
     $reason = $this->reason;
     $user = $this->getUser();
     $tags = array();
     // Is this a major change, or just a secondary change? Mark both for major
     if ($this->hasArabicLangLink()) {
         $tags[] = MarkMajorChanges::getSecondaryTagName();
     }
     if (!$this->isSecondaryChange) {
         $tags[] = MarkMajorChanges::getMainTagName();
     }
     // Should we use DeferredUpdates::addCallableUpdate?
     $status = ChangeTags::addTags($tags, null, $revId);
     if ($status === true) {
         $this->logTagAdded($tags, $revId, $user, $reason);
         //$this->getTitle()->isMajorChange == true;
         return true;
     }
     return false;
 }