http://www.mediawiki.org/wiki/Special:Code/MediaWiki/99157

Revision: 99157
Author:   brion
Date:     2011-10-06 22:26:46 +0000 (Thu, 06 Oct 2011)
Log Message:
-----------
MFT r99154, r99155 (bug 31352)

Modified Paths:
--------------
    branches/REL1_18/phase3/RELEASE-NOTES-1.18
    branches/REL1_18/phase3/languages/Language.php

Modified: branches/REL1_18/phase3/RELEASE-NOTES-1.18
===================================================================
--- branches/REL1_18/phase3/RELEASE-NOTES-1.18  2011-10-06 22:25:39 UTC (rev 
99156)
+++ branches/REL1_18/phase3/RELEASE-NOTES-1.18  2011-10-06 22:26:46 UTC (rev 
99157)
@@ -421,7 +421,6 @@
 * (bug 27410) The tag filter on a history page is now within a <label> element
 * (bug 29779) DairikiDiff/WikiDiff <ins> and <del> should undo browser default
   styling (strike/underline).
-* Translate the block expiry date
 * (bug 28630) Add iwlinks, langlinks, redirect to
   RefreshLinks::deleteLinksFromNonexistent
 * (bug 29797) Error: "Tried to load block with invalid type" when subpages

Modified: branches/REL1_18/phase3/languages/Language.php
===================================================================
--- branches/REL1_18/phase3/languages/Language.php      2011-10-06 22:25:39 UTC 
(rev 99156)
+++ branches/REL1_18/phase3/languages/Language.php      2011-10-06 22:26:46 UTC 
(rev 99157)
@@ -3007,8 +3007,12 @@
        }
 
        /**
-        * This translates the duration ("1 week", "4 days", etc)
-        * as well as the expiry time (which is an absolute timestamp).
+        * @todo Maybe translate block durations.  Note that this function is 
somewhat misnamed: it
+        * deals with translating the *duration* ("1 week", "4 days", etc), not 
the expiry time
+        * (which is an absolute timestamp). Please note: do NOT add this 
blindly, as it is used
+        * on old expiry lengths recorded in log entries. You'd need to provide 
the start date to
+        * match up with it.
+        *
         * @param $str String: the validated block duration in English
         * @return Somehow translated block duration
         * @see LanguageFi.php for example implementation
@@ -3032,8 +3036,8 @@
                                }
                        }
                }
-               // If no duration is given, but a timestamp, display that
-               return ( strtotime( $str ) ? $this->timeanddate( strtotime( 
$str ) ) : $str );
+               // If all else fails, return the original string.
+               return $str;
        }
 
        /**


_______________________________________________
MediaWiki-CVS mailing list
MediaWiki-CVS@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to