? Pending

User tests: Successful: Unsuccessful:

avatar mbabker
mbabker
13 Feb 2017

Summary of Changes

When using a Closure with the cache's callback controller, generating the ID will fail because it attempts to serialize a Closure which isn't allowed. Change the code to use an object hash for the Closure instead.

Testing Instructions

Probably should be easily triggered just by turning on caching for core because there are a few places where Closures are used now. Failing that, I guess something like this should work as a test case:

JFactory::getCache('_system', 'callback')->get(function () { echo 'Hello World!'; });

Expected result

Page displays correctly

Actual result

Page errors out due to attempted serialization of a Closure

Documentation Changes Required

N/A

avatar mbabker mbabker - open - 13 Feb 2017
avatar mbabker mbabker - change - 13 Feb 2017
Status New Pending
avatar mbabker mbabker - change - 13 Feb 2017
The description was changed
avatar mbabker mbabker - edited - 13 Feb 2017
avatar joomla-cms-bot joomla-cms-bot - change - 13 Feb 2017
Category Libraries
avatar mbabker mbabker - change - 13 Feb 2017
Labels Added: ?
avatar wilsonge
wilsonge - comment - 14 Feb 2017

Merging on code review and the test by @waader in #13262

avatar wilsonge wilsonge - change - 14 Feb 2017
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2017-02-14 15:45:15
Closed_By wilsonge
avatar wilsonge wilsonge - close - 14 Feb 2017
avatar wilsonge wilsonge - merge - 14 Feb 2017

Add a Comment

Login with GitHub to post a comment