Merge "Remove incorrect timezone conversion from date parameters"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Thu, 16 Aug 2018 20:28:10 +0000 (20:28 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Thu, 16 Aug 2018 20:28:10 +0000 (20:28 +0000)
includes/pager/RangeChronologicalPager.php
includes/specials/SpecialLog.php

index d3cb566..bf36983 100644 (file)
@@ -45,14 +45,12 @@ abstract class RangeChronologicalPager extends ReverseChronologicalPager {
                try {
                        if ( $startStamp !== '' ) {
                                $startTimestamp = MWTimestamp::getInstance( $startStamp );
-                               $startTimestamp->setTimezone( $this->getConfig()->get( 'Localtimezone' ) );
                                $startOffset = $this->mDb->timestamp( $startTimestamp->getTimestamp() );
                                $this->rangeConds[] = $this->mIndexField . '>=' . $this->mDb->addQuotes( $startOffset );
                        }
 
                        if ( $endStamp !== '' ) {
                                $endTimestamp = MWTimestamp::getInstance( $endStamp );
-                               $endTimestamp->setTimezone( $this->getConfig()->get( 'Localtimezone' ) );
                                $endOffset = $this->mDb->timestamp( $endTimestamp->getTimestamp() );
                                $this->rangeConds[] = $this->mIndexField . '<=' . $this->mDb->addQuotes( $endOffset );
 
index 2160312..d700c39 100644 (file)
@@ -64,8 +64,6 @@ class SpecialLog extends SpecialPage {
                $dateString = $this->getRequest()->getVal( 'wpdate' );
                if ( !empty( $dateString ) ) {
                        $dateStamp = MWTimestamp::getInstance( $dateString . ' 00:00:00' );
-                       $dateStamp->setTimezone( $this->getConfig()->get( 'Localtimezone' ) );
-
                        $opts->setValue( 'year', (int)$dateStamp->format( 'Y' ) );
                        $opts->setValue( 'month', (int)$dateStamp->format( 'm' ) );
                        $opts->setValue( 'day', (int)$dateStamp->format( 'd' ) );