mirror of
https://github.com/azaion/satellite-provider.git
synced 2026-06-27 09:01:13 +00:00
[AZ-1126] Migrate capturedAt to DateTimeOffset
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -80,9 +80,7 @@ public sealed class UavTileQualityGate : IUavTileQualityGate
|
||||
// Rule 4 (Captured-at age): forbid future timestamps beyond clock skew and
|
||||
// reject anything older than the configured max age.
|
||||
var now = _timeProvider.GetUtcNow().UtcDateTime;
|
||||
var capturedAt = metadata.CapturedAt.Kind == DateTimeKind.Utc
|
||||
? metadata.CapturedAt
|
||||
: metadata.CapturedAt.ToUniversalTime();
|
||||
var capturedAt = metadata.CapturedAt.UtcDateTime;
|
||||
|
||||
if (capturedAt > now.AddSeconds(_qualityConfig.CapturedAtFutureSkewSeconds))
|
||||
{
|
||||
|
||||
@@ -157,9 +157,7 @@ public sealed class UavTileUploadHandler : IUavTileUploadHandler
|
||||
var imageArray = imageBytes.ToArray();
|
||||
await File.WriteAllBytesAsync(filePath, imageArray, cancellationToken);
|
||||
|
||||
var capturedAtUtc = metadata.CapturedAt.Kind == DateTimeKind.Utc
|
||||
? metadata.CapturedAt
|
||||
: metadata.CapturedAt.ToUniversalTime();
|
||||
var capturedAtUtc = metadata.CapturedAt.UtcDateTime;
|
||||
var now = _timeProvider.GetUtcNow().UtcDateTime;
|
||||
|
||||
// AZ-503: deterministic id from (z, x, y, source, flight_id-or-zero) and
|
||||
|
||||
Reference in New Issue
Block a user