From 75b625970a1d8e5be80a16b13e475fc1de53db9c Mon Sep 17 00:00:00 2001 From: Noikoio Date: Fri, 3 May 2019 12:49:09 -0700 Subject: [PATCH] Remove redundant SyncLock --- BirthdayBot/BackgroundWorker.vb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/BirthdayBot/BackgroundWorker.vb b/BirthdayBot/BackgroundWorker.vb index 38bc37e..d47b85a 100644 --- a/BirthdayBot/BackgroundWorker.vb +++ b/BirthdayBot/BackgroundWorker.vb @@ -109,6 +109,7 @@ Class BackgroundWorker gs.RoleWarning = True Return 0 End If + gs.RoleWarning = False End SyncLock ' Determine who's currently having a birthday @@ -119,9 +120,6 @@ Class BackgroundWorker Dim announceNames As IEnumerable(Of SocketGuildUser) Try announceNames = Await BirthdayApplyAsync(guild, role, birthdays) - SyncLock _bot.KnownGuilds - _bot.KnownGuilds(guild.Id).RoleWarning = False - End SyncLock Catch ex As Discord.Net.HttpException If ex.HttpCode = HttpStatusCode.Forbidden Then SyncLock _bot.KnownGuilds