Already done in r33616 :)
jb
On 18 Apr 2011, at 02:45, Marc Laporte wrote:
> Hi!
>
> I have a 6.2 site that is getting performance issues related to this message:
> /home/..../lib/tikidate-php5.php on line 282
>
> Is this commit a suitable candidate for a backport to 6.x?
>
> Thanks!
>
> M ;-)
>
>
> On Tue, Mar 15, 2011 at 5:00 PM, <lphuberdeau@...> wrote:
>> Revision: 33400
>> http://tikiwiki.svn.sourceforge.net/tikiwiki/?rev=33400&view=rev
>> Author: lphuberdeau
>> Date: 2011-03-15 21:00:37 +0000 (Tue, 15 Mar 2011)
>>
>> Log Message:
>> -----------
>> [FIX] Make sure the datetime libraries are not called multiple time, saving a big chunk of execution time
>>
>> Modified Paths:
>> --------------
>> trunk/lib/tikidate-php5.php
>>
>> Modified: trunk/lib/tikidate-php5.php
>> ===================================================================
>> --- trunk/lib/tikidate-php5.php 2011-03-15 20:48:37 UTC (rev 33399)
>> +++ trunk/lib/tikidate-php5.php 2011-03-15 21:00:37 UTC (rev 33400)
>> @@ -275,10 +275,16 @@
>>
>> // Checks that the string is either a timezone identifier or an abbreviation. display_timezone can be manually set to an identifier in preferences but will be an [uppercase] abbreviation if auto-detected by JavaScript.
>> static function TimezoneIsValidId($id) {
>> - return array_key_exists( strtolower($id), DateTimeZone::listAbbreviations() ) ||
>> - in_array($id, DateTimeZone::listIdentifiers());
>> + static $abbrevs = null, $ids = null;
>> +
>> + if (! $abbrevs) {
>> + $abbrevs = DateTimeZone::listAbbreviations();
>> + $ids = DateTimeZone::listIdentifiers();
>> + }
>> +
>> + return array_key_exists( strtolower($id), $abbrevs ) ||
>> + in_array($id, $ids);
>> }
>> -
>> }
>>
>> class Date_Calc
>>
>>
>> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
>>
>> ------------------------------------------------------------------------------
>> Colocation vs. Managed Hosting
>> A question and answer guide to determining the best fit
>> for your organization - today and in the future.
>> http://p.sf.net/sfu/internap-sfd2d
>> _______________________________________________
>> Tikiwiki-cvs mailing list
>> Tikiwiki-cvs@...
>> https://lists.sourceforge.net/lists/listinfo/tikiwiki-cvs
>>
>
>
>
> --
> Marc Laporte
>
> http://MarcLaporte.com
> http://Tiki.org/MarcLaporte
> http://AvanTech.net
>
> ------------------------------------------------------------------------------
> Benefiting from Server Virtualization: Beyond Initial Workload
> Consolidation -- Increasing the use of server virtualization is a top
> priority.Virtualization can reduce costs, simplify management, and improve
> application availability and disaster protection. Learn more about boosting
> the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev
> _______________________________________________
> Tikiwiki-cvs mailing list
> Tikiwiki-cvs@...
> https://lists.sourceforge.net/lists/listinfo/tikiwiki-cvs
>
|