r50032 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r50031‎ | r50032 | r50033 >
Date:00:03, 29 April 2009
Author:yaron
Status:deferred
Tags:
Comment:
Fixed bug, to distinguish initializing based on a year from initializing based on a Julian day
Modified paths:
  • /trunk/extensions/SemanticMediaWiki/includes/SMW_DV_Time.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticMediaWiki/includes/SMW_DV_Time.php
@@ -96,8 +96,9 @@
9797
9898 $value = trim($value); // ignore whitespace
9999
100 - // if it's a number, treat it as a Julian day
101 - if (is_numeric($value)) {
 100+ // if it's a number, and it's sufficiently high, so we know
 101+ // it's not a year, treat it as a Julian day
 102+ if (is_numeric($value) && $value > 100000) {
102103 $this->m_jd = $value;
103104 $this->JD2Date();
104105 return true;

Status & tagging log