mirror of
https://github.com/NoiTheCat/BirthdayBot.git
synced 2024-11-21 05:54:36 +00:00
Bug fix and debug fix
This commit is contained in:
parent
d94c98aed2
commit
853e3092f0
2 changed files with 5 additions and 4 deletions
4
.vscode/launch.json
vendored
4
.vscode/launch.json
vendored
|
@ -10,8 +10,8 @@
|
|||
"request": "launch",
|
||||
"preLaunchTask": "build",
|
||||
// If you have changed target frameworks, make sure to update the program path.
|
||||
"program": "${workspaceFolder}/bin/Debug/net6.0/BirthdayBot.dll",
|
||||
"args": [ "-c", "${workspaceFolder}/bin/Debug/net6.0/settings.json" ],
|
||||
"program": "${workspaceFolder}/bin/Debug/net8.0/BirthdayBot.dll",
|
||||
"args": [ "-c", "${workspaceFolder}/bin/Debug/settings.json" ],
|
||||
"cwd": "${workspaceFolder}",
|
||||
// For more information about the 'console' field, see https://aka.ms/VSCode-CS-LaunchJson-Console
|
||||
"console": "internalConsole",
|
||||
|
|
|
@ -141,7 +141,7 @@ public class ConfigModule : BotModuleBase {
|
|||
var result = new StringBuilder();
|
||||
|
||||
result.AppendLine($"Server ID: `{guild.Id}` | Bot shard ID: `{Shard.ShardId:00}`");
|
||||
result.AppendLine($"Number of registered birthdays: `{guildconf.UserEntries.Count}`");
|
||||
result.AppendLine($"Number of registered birthdays: `{guildconf.UserEntries?.Count ?? 0}`");
|
||||
result.AppendLine($"Server time zone: `{guildconf.GuildTimeZone ?? "Not set - using UTC"}`");
|
||||
result.AppendLine();
|
||||
|
||||
|
@ -152,7 +152,8 @@ public class ConfigModule : BotModuleBase {
|
|||
result.Append(DoTestFor("Birthday processing", delegate {
|
||||
if (!hasMembers) return false;
|
||||
if (guildconf.IsNew) return false;
|
||||
bdayCount = BackgroundServices.BirthdayRoleUpdate.GetGuildCurrentBirthdays(guildconf.UserEntries, guildconf.GuildTimeZone).Count;
|
||||
bdayCount = BackgroundServices.BirthdayRoleUpdate
|
||||
.GetGuildCurrentBirthdays(guildconf.UserEntries!, guildconf.GuildTimeZone).Count;
|
||||
return true;
|
||||
}));
|
||||
if (!hasMembers) result.AppendLine(" - Previous step failed.");
|
||||
|
|
Loading…
Reference in a new issue