diff --git a/sources/GeneratorSdk/MetadataTasks/ScrapeHeaders.cs b/sources/GeneratorSdk/MetadataTasks/ScrapeHeaders.cs index 116c79d5..38c77103 100644 --- a/sources/GeneratorSdk/MetadataTasks/ScrapeHeaders.cs +++ b/sources/GeneratorSdk/MetadataTasks/ScrapeHeaders.cs @@ -475,7 +475,7 @@ private string[] GetRemaps(ITaskItem item) private string[] GetFilesFromMetadata(ITaskItem item, string name) { - string[] items = item.GetMetadata(name).Split(';', System.StringSplitOptions.RemoveEmptyEntries); + string[] items = item.GetMetadata(name).Split(';', System.StringSplitOptions.RemoveEmptyEntries | System.StringSplitOptions.TrimEntries); for (int i = 0; i < items.Length; i++) { if (!Path.IsPathRooted(items[i]))