diff --git a/src/Stars.Data.Tests/Resources/SATELLOGIC/NEWSAT/MetadataExtractorsTests_20241102_105919_SN48_L1D_SR_MS_251827.json b/src/Stars.Data.Tests/Resources/SATELLOGIC/NEWSAT/MetadataExtractorsTests_20241102_105919_SN48_L1D_SR_MS_251827.json index 8ed53c46..b18bd3eb 100644 --- a/src/Stars.Data.Tests/Resources/SATELLOGIC/NEWSAT/MetadataExtractorsTests_20241102_105919_SN48_L1D_SR_MS_251827.json +++ b/src/Stars.Data.Tests/Resources/SATELLOGIC/NEWSAT/MetadataExtractorsTests_20241102_105919_SN48_L1D_SR_MS_251827.json @@ -289,7 +289,7 @@ ], "filename": "20241102_105919_SN48_L1D_SR_MS_TOA_0.tif" }, - "cloud": { + "cloud_mask": { "type": "application/xml", "roles": [ "cloud" diff --git a/src/Stars.Data/Model/Metadata/NewSat/NewSatMetadataExtractor.cs b/src/Stars.Data/Model/Metadata/NewSat/NewSatMetadataExtractor.cs index 88ad24b3..cd8639aa 100644 --- a/src/Stars.Data/Model/Metadata/NewSat/NewSatMetadataExtractor.cs +++ b/src/Stars.Data/Model/Metadata/NewSat/NewSatMetadataExtractor.cs @@ -84,6 +84,12 @@ protected override async Task ExtractMetadata(IItem item, string suffi // add L3 visual tif asset bool x = AddL3Assets(item, stacItem) || AddL1Assets(item, stacItem); + if (!stacItem.Assets.ContainsKey("cloud_mask") && stacItem.Assets.ContainsKey("cloud")) + { + stacItem.Assets["cloud_mask"] = stacItem.Assets["cloud"]; + stacItem.Assets.Remove("cloud"); + } + return StacNode.Create(stacItem, item.Uri); }