1
0
mirror of https://github.com/bitwarden/server synced 2025-12-06 00:03:34 +00:00

[BEEEP] Fix all CA2254 occurrences (#6357)

* Fix all CA2254 occurrences

* Fix tests
This commit is contained in:
Justin Baur
2025-10-20 11:34:31 -04:00
committed by GitHub
parent 43779cf2e8
commit c6f1acede9
21 changed files with 45 additions and 35 deletions

View File

@@ -107,7 +107,7 @@ public abstract class BaseJobsHostedService : IHostedService, IDisposable
throw new Exception("Job failed to start after 10 retries.");
}
_logger.LogWarning($"Exception while trying to schedule job: {job.FullName}, {e}");
_logger.LogWarning(e, "Exception while trying to schedule job: {JobName}", job.FullName);
var random = new Random();
await Task.Delay(random.Next(50, 250));
}
@@ -125,7 +125,7 @@ public abstract class BaseJobsHostedService : IHostedService, IDisposable
continue;
}
_logger.LogInformation($"Deleting old job with key {key}");
_logger.LogInformation("Deleting old job with key {Key}", key);
await _scheduler.DeleteJob(key);
}
@@ -138,7 +138,7 @@ public abstract class BaseJobsHostedService : IHostedService, IDisposable
continue;
}
_logger.LogInformation($"Unscheduling old trigger with key {key}");
_logger.LogInformation("Unscheduling old trigger with key {Key}", key);
await _scheduler.UnscheduleJob(key);
}
}