ZF-9979: Function Cache makeid 'Incorrect function name'


When using call like in the call_user_func_array docs example…, if we try to call the method of an object, it throws Zend_Cache::throwException('Incorrect function name');

Example: $api = new MyApi(); $xml = $cache->call(array($api, 'searchProducts'), $args);

So I would modify the "incorrect..." by this: if (!is_string($name)) { //Zend_Cache::throwException('Incorrect function name'); $name = print_r($name, true); }


To clarify, this is how the _makeid of the Zend_Cache_Frontend_Function should look like:

private function _makeId($name, $parameters)
    if (!is_string($name)) {
        //Zend_Cache::throwException('Incorrect function name');
        $name = print_r($name, true);
    if (!is_array($parameters)) {
        Zend_Cache::throwException('parameters argument must be an array');
    return md5($name . serialize($parameters));

I committed some changes to the function frontend to allow all types of callbacks. (r22503 @ trunk)

Please tell me if it will close your issue.

fixed in r22504 (1.10 branch) & r22503 (trunk)