Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 2.0.4

Bug #3914 Translation2 'CacheMemory' Decorator class get() bug!
Submitted: 2005-03-22 11:05 UTC
From: ivanchoo at singnet dot com dot sg Assigned: quipo
Status: Closed Package: Translation2
PHP Version: 4.3.10 OS: Darwin OS X
Roadmaps: (Not assigned)    
Subscription  


 [2005-03-22 11:05 UTC] ivanchoo at singnet dot com dot sg
Description: ------------ The decorator does not cache upon prefetch, as the get() method wrongly calls the getRawPage() instead of getPage(). Changing the code fixes this problem. Reproduce code: --------------- function get() { ... if ($this->prefetch) { $this->getRawPage($pageID, $langID); } to if ($this->prefetch) { $this->getPage($pageID, $langID); }

Comments

 [2005-03-26 14:05 UTC] quipo
Actually, this was done on purpose [1] because it conflicted with parameter substitution. @see http://pear.php.net/bugs/bug.php?id=2972 Michael, Ian, do you have any idea how to fix this issue without breaking the other fix? [1] http://cvs.php.net/diff.php/pear/Translation2/Decorator/CacheMemory.php?r1=1.4&r2=1.5&ty=h&num=10
 [2005-03-26 14:06 UTC] quipo
I've added a testcase to test that parameter substitution works as expected