Skip to content

Commit

Permalink
fix(config): cache won't flush when config add
Browse files Browse the repository at this point in the history
  • Loading branch information
GZTimeWalker committed May 13, 2024
1 parent 113f060 commit 0dab8f2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/GZCTF/Services/ConfigService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,15 @@ public async Task SaveConfigSet(HashSet<Config> configs, CancellationToken token
}
else
{
if (conf.CacheKeys is not null)
cacheKeys.UnionWith(conf.CacheKeys);

await context.Configs.AddAsync(conf, token);

logger.SystemLog(
Program.StaticLocalizer[nameof(Resources.Program.Config_GlobalConfigAdded), conf.ConfigKey,
conf.Value ?? "null"],
TaskStatus.Success, LogLevel.Debug);
await context.Configs.AddAsync(conf, token);
}
}

Expand Down

0 comments on commit 0dab8f2

Please sign in to comment.