protected function fetchMethodArguments(MethodInvocation $invocation)
{
$parameters = $invocation->getMethod()->getParameters();
$argumentNames = array_map(function (\ReflectionParameter $parameter) {
return $parameter->name;
}, $parameters);
$parameters = array_combine($argumentNames, $invocation->getArguments());
return $parameters;
}