https://bugzilla.wikimedia.org/show_bug.cgi?id=30395
Web browser: ---
Bug #: 30395
Summary: Date type does not handle a sole year value correctly
Product: MediaWiki extensions
Version: any
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: Semantic MediaWiki
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
Classification: Unclassified
If a property of type::Date (submittedOn for example) is created and then
assigned a single value of a single year e.g:
[[submittedOn::2011]]
then the value is not parsed correctly. The problem is in
datavalues/SMW_DV_Time.php:149 and is the MediaWiki wfTimestamp() function. It
doesn't correctly parse the year, but returns a value anyway. I did a quick
test:
if ( $timeStamp !== false && $timeStamp != 19700101003332 ) {
and that fixed the problem. Obviously it's not a good solution, the wfTimestamp
function probably needs to be fixed.
--
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l