Fix bot things 2

This commit is contained in:
2025-02-11 02:06:35 +07:00
parent 898ff85eed
commit d7731dda0e
10 changed files with 164 additions and 121 deletions

View File

@@ -34,8 +34,9 @@ public class BotRepository : IBotRepository
_botRepository.Update(dto);
}
public void DeleteBotBackup(string botName)
public async Task DeleteBotBackup(string botName)
{
_botRepository.DeleteOne(b => b.Name == botName);
var backup = await _botRepository.FindOneAsync(b => b.Name == botName);
await _botRepository.DeleteOneAsync(b => b.Id == backup.Id);
}
}