mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
Throw caught exceptions in HTTPCacheControlMiddleware::process
This commit is contained in:
parent
37343cf0e2
commit
6bb69d1ae5
@ -33,6 +33,7 @@ class HTTPCacheControlMiddleware implements HTTPMiddleware, Resettable
|
|||||||
* @param HTTPRequest $request
|
* @param HTTPRequest $request
|
||||||
* @param callable $delegate
|
* @param callable $delegate
|
||||||
* @return HTTPResponse
|
* @return HTTPResponse
|
||||||
|
* @throws HTTPResponse_Exception
|
||||||
*/
|
*/
|
||||||
public function process(HTTPRequest $request, callable $delegate)
|
public function process(HTTPRequest $request, callable $delegate)
|
||||||
{
|
{
|
||||||
@ -50,6 +51,9 @@ class HTTPCacheControlMiddleware implements HTTPMiddleware, Resettable
|
|||||||
}
|
}
|
||||||
|
|
||||||
HTTP::add_cache_headers($response);
|
HTTP::add_cache_headers($response);
|
||||||
|
if (isset($ex)) {
|
||||||
|
throw $ex;
|
||||||
|
}
|
||||||
return $response;
|
return $response;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user