/** * @param ApiPageSet $pageSet * @return void */ public function requestExtraData($pageSet) { $pageSet->requestField('page_restrictions'); // If the pageset is resolving redirects we won't get page_is_redirect. // But we can't know for sure until the pageset is executed (revids may // turn it off), so request it unconditionally. $pageSet->requestField('page_is_redirect'); $pageSet->requestField('page_is_new'); $config = $this->getConfig(); $pageSet->requestField('page_touched'); $pageSet->requestField('page_latest'); $pageSet->requestField('page_len'); if ($config->get('ContentHandlerUseDB')) { $pageSet->requestField('page_content_model'); } if ($config->get('PageLanguageUseDB')) { $pageSet->requestField('page_lang'); } }
/** * @param ApiPageSet $pageSet * @return void */ public function requestExtraData($pageSet) { $pageSet->requestField('page_restrictions'); // when resolving redirects, no page will have this field if (!$pageSet->isResolvingRedirects()) { $pageSet->requestField('page_is_redirect'); } $pageSet->requestField('page_is_new'); $config = $this->getConfig(); if (!$config->get('DisableCounters')) { $pageSet->requestField('page_counter'); } $pageSet->requestField('page_touched'); $pageSet->requestField('page_latest'); $pageSet->requestField('page_len'); if ($config->get('ContentHandlerUseDB')) { $pageSet->requestField('page_content_model'); } }