diff --git a/src/Command/RefreshLatestActiveJobOrderCacheCommand.php b/src/Command/RefreshLatestActiveJobOrderCacheCommand.php index d37636de..26a555ee 100644 --- a/src/Command/RefreshLatestActiveJobOrderCacheCommand.php +++ b/src/Command/RefreshLatestActiveJobOrderCacheCommand.php @@ -40,9 +40,14 @@ class RefreshLatestActiveJobOrderCacheCommand extends Command protected function execute(InputInterface $input, OutputInterface $output) { + // for logging purposes + $tmp_cache_log = fopen('/tmp/cache_logs.txt', 'a'); + // remove all entries in cache $this->jo_cache->clearLatestActiveJobOrderCache(); + fwrite($tmp_cache_log, 'Cleared latest active jo cache...' . "\n"); + $date = new DateTime(); $date->modify('-1 day'); @@ -70,6 +75,9 @@ class RefreshLatestActiveJobOrderCacheCommand extends Command $this->jo_cache->addLatestActiveJoborder($jo); } + fwrite($tmp_cache_log, 'Refreshed latest active jo cache...' . "\n"); + fclose($tmp_cache_log); + return 0; } }