chore: create migration snapshot

This commit is contained in:
Fu Diwei
2025-02-14 00:27:25 +08:00
parent d588e14a58
commit fe93334f86
14 changed files with 350 additions and 856 deletions

View File

@@ -41,13 +41,13 @@ func NewCertificateService(certRepo certificateRepository) *CertificateService {
func (s *CertificateService) InitSchedule(ctx context.Context) error {
app.GetScheduler().MustAdd("certificateExpireSoonNotify", "0 0 * * *", func() {
certs, err := s.certRepo.ListExpireSoon(context.Background())
certificates, err := s.certRepo.ListExpireSoon(context.Background())
if err != nil {
app.GetLogger().Error("failed to get certificates which expire soon", "err", err)
return
}
notification := buildExpireSoonNotification(certs)
notification := buildExpireSoonNotification(certificates)
if notification == nil {
return
}