@@ -5,7 +5,7 @@ internal class PunishmentTasks
5
5
public static async Task < bool > CheckBansAsync ( )
6
6
{
7
7
DiscordGuild targetGuild = Program . homeGuild ;
8
- Dictionary < string , MemberPunishment > banList = Program . db . HashGetAll ( "bans" ) . ToDictionary (
8
+ Dictionary < string , MemberPunishment > banList = ( await Program . db . HashGetAllAsync ( "bans" ) ) . ToDictionary (
9
9
x => x . Name . ToString ( ) ,
10
10
x => JsonConvert . DeserializeObject < MemberPunishment > ( x . Value )
11
11
) ;
@@ -34,7 +34,7 @@ public static async Task<bool> CheckBansAsync()
34
34
}
35
35
public static async Task < bool > CheckMutesAsync ( )
36
36
{
37
- Dictionary < string , MemberPunishment > muteList = Program . db . HashGetAll ( "mutes" ) . ToDictionary (
37
+ Dictionary < string , MemberPunishment > muteList = ( await Program . db . HashGetAllAsync ( "mutes" ) ) . ToDictionary (
38
38
x => x . Name . ToString ( ) ,
39
39
x => JsonConvert . DeserializeObject < MemberPunishment > ( x . Value )
40
40
) ;
@@ -69,7 +69,7 @@ public static async Task<bool> CleanUpPunishmentMessagesAsync()
69
69
70
70
if ( Program . cfgjson . AutoWarnMsgAutoDeleteDays > 0 )
71
71
{
72
- Dictionary < string , UserWarning > warnList = Program . db . HashGetAll ( "automaticWarnings" ) . ToDictionary (
72
+ Dictionary < string , UserWarning > warnList = ( await Program . db . HashGetAllAsync ( "automaticWarnings" ) ) . ToDictionary (
73
73
x => x . Name . ToString ( ) ,
74
74
x => JsonConvert . DeserializeObject < UserWarning > ( x . Value )
75
75
) ;
@@ -102,7 +102,7 @@ public static async Task<bool> CleanUpPunishmentMessagesAsync()
102
102
103
103
if ( Program . cfgjson . CompromisedAccountBanMsgAutoDeleteDays > 0 )
104
104
{
105
- Dictionary < string , MemberPunishment > banList = Program . db . HashGetAll ( "compromisedAccountBans" ) . ToDictionary (
105
+ Dictionary < string , MemberPunishment > banList = ( await Program . db . HashGetAllAsync ( "compromisedAccountBans" ) ) . ToDictionary (
106
106
x => x . Name . ToString ( ) ,
107
107
x => JsonConvert . DeserializeObject < MemberPunishment > ( x . Value )
108
108
) ;
0 commit comments