public static function serializeAdvice(Closure $adviceMethod) { $refAdvice = new ReflectionFunction($adviceMethod); return ['method' => $refAdvice->name, 'aspect' => get_class($refAdvice->getClosureThis())]; }