|
@@ -85,14 +85,16 @@ class ProfilerListener
|
|
$response = $event->getResponse();
|
|
$response = $event->getResponse();
|
|
|
|
|
|
if ($this->onlyMasterRequests && HttpKernelInterface::MASTER_REQUEST !== $event->getRequestType()) {
|
|
if ($this->onlyMasterRequests && HttpKernelInterface::MASTER_REQUEST !== $event->getRequestType()) {
|
|
- return $response;
|
|
|
|
|
|
+ return;
|
|
}
|
|
}
|
|
|
|
|
|
- if (null !== $this->matcher && !$this->matcher->matches($event->getRequest())) {
|
|
|
|
- return $response;
|
|
|
|
|
|
+ if ($this->onlyException && null === $this->exception) {
|
|
|
|
+ return;
|
|
}
|
|
}
|
|
|
|
|
|
- if ($this->onlyException && null === $this->exception) {
|
|
|
|
|
|
+ $this->exception = null;
|
|
|
|
+
|
|
|
|
+ if (null !== $this->matcher && !$this->matcher->matches($event->getRequest())) {
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
|
|
|
|
@@ -103,6 +105,5 @@ class ProfilerListener
|
|
}
|
|
}
|
|
|
|
|
|
$profiler->collect($event->getRequest(), $event->getResponse(), $this->exception);
|
|
$profiler->collect($event->getRequest(), $event->getResponse(), $this->exception);
|
|
- $this->exception = null;
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|