Skip to content

Commit e3f97af

Browse files
committed
Update dispatch call
1 parent 99e856b commit e3f97af

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/CacheInvalidator.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -311,9 +311,9 @@ public function flush()
311311
$event = new Event();
312312
$event->setException($exception);
313313
if ($exception instanceof ProxyResponseException) {
314-
$this->getEventDispatcher()->dispatch(Events::PROXY_RESPONSE_ERROR, $event);
314+
$this->getEventDispatcher()->dispatch($event, Events::PROXY_RESPONSE_ERROR);
315315
} elseif ($exception instanceof ProxyUnreachableException) {
316-
$this->getEventDispatcher()->dispatch(Events::PROXY_UNREACHABLE_ERROR, $event);
316+
$this->getEventDispatcher()->dispatch($event, Events::PROXY_UNREACHABLE_ERROR);
317317
}
318318
}
319319

src/SymfonyCache/EventDispatchingHttpCache.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ protected function dispatch($name, Request $request, Response $response = null,
145145
{
146146
if ($this->getEventDispatcher()->hasListeners($name)) {
147147
$event = new CacheEvent($this, $request, $response, $requestType);
148-
$this->getEventDispatcher()->dispatch($name, $event);
148+
$this->getEventDispatcher()->dispatch($event, $name);
149149
$response = $event->getResponse();
150150
}
151151

0 commit comments

Comments
 (0)