From a48b5f01c910019bc329291e76f1522a1c0c5e40 Mon Sep 17 00:00:00 2001 From: Tomahock Date: Mon, 8 Jul 2024 12:49:50 +0100 Subject: [PATCH] fix bug --- app/Jobs/ProcessANPCAllDataV2.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/app/Jobs/ProcessANPCAllDataV2.php b/app/Jobs/ProcessANPCAllDataV2.php index dddfac2..a67a43f 100644 --- a/app/Jobs/ProcessANPCAllDataV2.php +++ b/app/Jobs/ProcessANPCAllDataV2.php @@ -93,11 +93,14 @@ public function handle() } } else { if( $diff >= 10){ - DiscordTool::postError('A API não atualiza ha 10 minutos'); - $last['notify'] = true; + if(!$last['notify']){ + DiscordTool::postError('A API não atualiza ha 10 minutos'); + $last['notify'] = true; + $x[] = $last; + } + } - $x[] = $last; } file_put_contents('history.json', json_encode($x));