Skip to content

Commit

Permalink
Merge pull request Elgg#14487 from jeabakker/features
Browse files Browse the repository at this point in the history
fix(cache): report HTTP 410 Gone on stale cache urls
  • Loading branch information
jdalsem authored Oct 11, 2023
2 parents 9ce240a + cfd4883 commit babdcae
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions engine/classes/Elgg/Application/CacheHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,9 @@ public function handleRequest(Request $request, Application $app) {
$this->simplecache->cacheAsset($viewtype, $view, $content);
} else {
// if wrong timestamp, don't send HTTP cache
// also report that the resource has gone away
$response->setStatusCode(ELGG_HTTP_GONE);

$content = $this->getProcessedView($view, $viewtype);
}

Expand Down

0 comments on commit babdcae

Please sign in to comment.