private static function flattenArgument (&$value, $key) {
        if ($value instanceof Closure) {
            $closureReflection = new ReflectionFunction($value);
            $value = sprintf('(Closure at %s:%s)', $closureReflection->getFileName(), $closureReflection->getStartLine());
        } elseif (is_object($value)) {
            $value = sprintf('object(%s)', get_class($value));
        } elseif (is_resource($value)) {
            $value = sprintf('resource(%s)', get_resource_type($value));
        }
    }
private static function flattenArgument (&$value, $key) {
        if ($value instanceof Closure) {
            $closureReflection = new ReflectionFunction($value);
            $value = sprintf('(Closure at %s:%s)', $closureReflection->getFileName(), $closureReflection->getStartLine());
        } elseif (is_object($value)) {
            $value = sprintf('object(%s)', get_class($value));
        } elseif (is_resource($value)) {
            $value = sprintf('resource(%s)', get_resource_type($value));
        }
    }
private static function flattenArgument ( & $ value , $ key ) { if ( $ value instanceof Closure ) { $ closureReflection = new ReflectionFunction ( $ value ) ; $ value = sprintf ( '(Closure at %s:%s)' , $ closureReflection -> getFileName ( ) , $ closureReflection -> getStartLine ( ) ) ; } elseif ( is_object ( $ value ) ) { $ value = sprintf ( 'object(%s)' , get_class ( $ value ) ) ; } elseif ( is_resource ( $ value ) ) { $ value = sprintf ( 'resource(%s)' , get_resource_type ( $ value ) ) ; } }
Limpia de Clousures un argumento para que pueda ser serializable
@param mixed $value Valor del argumento
@param mixed $key Llave del argumento
@throws ReflectionException
Limpia de Clousures un argumento para que pueda ser serializable