src/Control/Middleware/ChangeDetectionMiddleware.php
protected function sendNotModified(HTTPRequest $request, HTTPResponse $response)
    {
        // 304 is invalid for destructive requests
        if (in_array($request->httpMethod(), ['POST', 'DELETE', 'PUT'])) {
            $response->setStatusCode(412);
        } else {
            $response->setStatusCode(304);
        }
        $response->setBody('');
        return $response;
    }
protected function sendNotModified(HTTPRequest $request, HTTPResponse $response)
    {
        // 304 is invalid for destructive requests
        if (in_array($request->httpMethod(), ['POST', 'DELETE', 'PUT'])) {
            $response->setStatusCode(412);
        } else {
            $response->setStatusCode(304);
        }
        $response->setBody('');
        return $response;
    }
protected function sendNotModified ( HTTPRequest $ request , HTTPResponse $ response ) { // 304 is invalid for destructive requests if ( in_array ( $ request -> httpMethod ( ) , [ 'POST' , 'DELETE' , 'PUT' ] ) ) { $ response -> setStatusCode ( 412 ) ; } else { $ response -> setStatusCode ( 304 ) ; } $ response -> setBody ( '' ) ; return $ response ; }
Sent not-modified response

@param HTTPRequest $request
@param HTTPResponse $response
@return mixed
Sent not - modified response