mirror of
https://github.com/xcp-ng/xenadmin.git
synced 2024-11-23 12:30:50 +01:00
Checking how long ago the pool was last synced should be done in relation to the server time.
Signed-off-by: Konstantina Chremmou <Konstantina.Chremmou@cloud.com>
This commit is contained in:
parent
03eb2f08d1
commit
f3874a85f8
@ -66,7 +66,7 @@ namespace XenAdmin.Alerts
|
||||
if (Helpers.XapiEqualOrGreater_23_18_0(connection))
|
||||
{
|
||||
var pool = Helpers.GetPoolOfOne(connection);
|
||||
var timestamp = DateTime.UtcNow;
|
||||
var timestamp = DateTime.UtcNow - connection.ServerTimeOffset;
|
||||
|
||||
if (timestamp - pool.last_update_sync >= TimeSpan.FromDays(90))
|
||||
{
|
||||
@ -120,7 +120,7 @@ namespace XenAdmin.Alerts
|
||||
public static bool TryCreate(IXenConnection connection, out Alert alert)
|
||||
{
|
||||
var pool = Helpers.GetPoolOfOne(connection);
|
||||
var timestamp = DateTime.UtcNow;
|
||||
var timestamp = DateTime.UtcNow - connection.ServerTimeOffset;
|
||||
|
||||
if (pool.repositories.Count == 0)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user