Skip to content

Commit

Permalink
Change the location of the categories cache
Browse files Browse the repository at this point in the history
was: /var/db/freshports/cache/general/categories.php
now: /var/db/freshports/cache/html/categories.php

Why?

* cache/general can be cleared at any time - this entity is different
  and is to be always present and replaced only when a new file is
  ready.
* since the new file will be created by the backend (ingress node),
  we put it in cache/html instead.
  • Loading branch information
dlangille committed Nov 11, 2023
1 parent 67248cb commit bab6720
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion www/search.php
Original file line number Diff line number Diff line change
Expand Up @@ -1121,7 +1121,7 @@ function WildCardQuery($db, $stype, $Like, $query) {

<?php
# the goal: have a periodic script which refreshes this file avoiding race conditions, e.g. mv
define('CATEGORIES_CACHE_LIST', '/var/db/freshports/cache/general/categories.php');
define('CATEGORIES_CACHE_LIST', '/var/db/freshports/cache/html/categories.php');

if (file_exists(CATEGORIES_CACHE_LIST)) {
?>
Expand Down

0 comments on commit bab6720

Please sign in to comment.