From 3462a7b7236b9f2abc3114715687003621bdfe85 Mon Sep 17 00:00:00 2001 From: JoshuaMicallefYBSU <91457812+JoshuaMicallefYBSU@users.noreply.github.com> Date: Mon, 21 Oct 2024 04:12:48 +1000 Subject: [PATCH 1/2] Update DiscordAccountCheck.php --- app/Jobs/DiscordAccountCheck.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/Jobs/DiscordAccountCheck.php b/app/Jobs/DiscordAccountCheck.php index 0ad7fefb..e7770761 100644 --- a/app/Jobs/DiscordAccountCheck.php +++ b/app/Jobs/DiscordAccountCheck.php @@ -205,13 +205,15 @@ public function handle() foreach($discord_uids as $discord_uid){ $accounts_not_linked++; //records that Account Not Linked Role Assigned + sleep(2); + // add role $discord->getClient()->put('guilds/'.env('DISCORD_GUILD_ID').'/members/'.$discord_uid.'/roles/1297422968472997908'); $discord->sendMessageWithEmbed( '1297517512904409099', - 'NOT LINKED - '.$user->fullName('FLC'), - 'User is not linked with CZQO.', + 'NOT LINKED - '.$discord_uid, + 'Discord User is not connected with Gander Oceanic.', ); } From 59a4e62f330f3db3b71f60af7ddb3fb730ee54cd Mon Sep 17 00:00:00 2001 From: JoshuaMicallefYBSU <91457812+JoshuaMicallefYBSU@users.noreply.github.com> Date: Mon, 21 Oct 2024 04:20:46 +1000 Subject: [PATCH 2/2] Update DiscordAccountCheck.php --- app/Jobs/DiscordAccountCheck.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Jobs/DiscordAccountCheck.php b/app/Jobs/DiscordAccountCheck.php index e7770761..7e997e0a 100644 --- a/app/Jobs/DiscordAccountCheck.php +++ b/app/Jobs/DiscordAccountCheck.php @@ -73,7 +73,7 @@ public function handle() } // Add a Sleep Timer - Allows API to not block - sleep(3); + sleep(1); // Check if user is currently in Discord if (in_array($user->discord_user_id, $discord_uids)) { @@ -205,7 +205,7 @@ public function handle() foreach($discord_uids as $discord_uid){ $accounts_not_linked++; //records that Account Not Linked Role Assigned - sleep(2); + sleep(1); // add role $discord->getClient()->put('guilds/'.env('DISCORD_GUILD_ID').'/members/'.$discord_uid.'/roles/1297422968472997908');