From 1b3e5c5ef84087e7d2db85c99ce2335b8f1988d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ma=C3=ABl=20Gangloff?= Date: Wed, 18 Dec 2024 22:53:26 +0100 Subject: [PATCH] feat: update weekly if removed from WHOIS --- .../tracking/watchlist/WatchlistCard.tsx | 2 +- src/Entity/Domain.php | 23 ++++++++++++------- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/assets/components/tracking/watchlist/WatchlistCard.tsx b/assets/components/tracking/watchlist/WatchlistCard.tsx index ea55f40..b7a66e7 100644 --- a/assets/components/tracking/watchlist/WatchlistCard.tsx +++ b/assets/components/tracking/watchlist/WatchlistCard.tsx @@ -80,7 +80,7 @@ export function WatchlistCard({watchlist, onUpdateWatchlist, connectors, onDelet dataSource={[{ domains: watchlist.domains.map(d => getUpdatedAt() - ->diff(new \DateTimeImmutable())->days >= 7 - || (($fromUser || ($this->getUpdatedAt() + return $this->getUpdatedAt()->diff(new \DateTimeImmutable())->days >= 7 + || $this->getDeleted() + ? $fromUser + : ( + ($fromUser || ($this->getUpdatedAt() ->diff(new \DateTimeImmutable())->h * 60 + $this->getUpdatedAt() - ->diff(new \DateTimeImmutable())->i) >= 50) - && $this->isToBeWatchClosely()) - - || (count(array_intersect($this->getStatus(), ['auto renew period', 'client hold', 'server hold'])) > 0 - && $this->getUpdatedAt()->diff(new \DateTimeImmutable())->days >= 1); + ->diff(new \DateTimeImmutable())->i) >= 50 + ) + && $this->isToBeWatchClosely() + ) + || ( + false == $this->getDeleted() && ( + count(array_intersect($this->getStatus(), ['auto renew period', 'client hold', 'server hold'])) > 0 + && $this->getUpdatedAt()->diff(new \DateTimeImmutable())->days >= 1 + ) + ); } /**