diff options
author | Andrew Dolgov <[email protected]> | 2021-02-28 12:23:36 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2021-02-28 12:23:36 +0300 |
commit | ec55ed61eb1fb1ea56e4228f0bb25fd62d093246 (patch) | |
tree | 34d44446c65215f20393ca366e82a93c5fc690e0 | |
parent | b9ab3595a7c117131d4dcc99d3c0b32028dd8ed2 (diff) |
reduce debugging
-rwxr-xr-x | init.php | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -145,16 +145,16 @@ class Reddit_Delay extends Plugin { $cutoff_timestamp = time() - ($delay * 60 * 60); - Debug::log(sprintf("[delay] %s [%s vs %s]", - $item->get_link(), - date("Y-m-d H:i:s", $item->get_date()), - date("Y-m-d H:i:s", $cutoff_timestamp)), Debug::$LOG_EXTENDED); - if ($item->get_date() > $cutoff_timestamp) { + Debug::log(sprintf("[delay] %s [%s vs %s]", + $item->get_link(), + date("Y-m-d H:i:s", $item->get_date()), + date("Y-m-d H:i:s", $cutoff_timestamp)), Debug::$LOG_EXTENDED); + if ($this->cache_exists($feed_id, $item->get_link())) { - Debug::log("[delay] article is too new, already cached.", Debug::$LOG_EXTENDED); + Debug::log("[delay] already stored.", Debug::$LOG_EXTENDED); } else { - Debug::log("[delay] article is too new, delaying it.", Debug::$LOG_EXTENDED); + Debug::log("[delay] storing in the backlog.", Debug::$LOG_EXTENDED); $this->cache_push($feed_id, $item, $entry); } |