✨ Social credit validation and recalculation
This commit is contained in:
21
DysonNetwork.Pass/Credit/SocialCreditValidationJob.cs
Normal file
21
DysonNetwork.Pass/Credit/SocialCreditValidationJob.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
using Quartz;
|
||||
|
||||
namespace DysonNetwork.Pass.Credit;
|
||||
|
||||
public class SocialCreditValidationJob(SocialCreditService socialCreditService, ILogger<SocialCreditValidationJob> logger) : IJob
|
||||
{
|
||||
public async Task Execute(IJobExecutionContext context)
|
||||
{
|
||||
logger.LogInformation("Starting social credit validation...");
|
||||
|
||||
try
|
||||
{
|
||||
await socialCreditService.ValidateSocialCredits();
|
||||
logger.LogInformation("Social credit validation completed successfully.");
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
logger.LogError(ex, "Error occurred during social credit validation.");
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user