Skip to content

Commit 978a13c

Browse files
committed
Some more fixes from code review
1 parent b06001c commit 978a13c

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/MigrationTools/Tools/ExportWorkItemMappingTool.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ public class ExportWorkItemMappingTool : Tool<ExportWorkItemMappingToolOptions>,
2222
WriteIndented = true,
2323
};
2424

25-
private readonly ConcurrentDictionary<string, string> _mappings = [];
25+
private readonly ConcurrentDictionary<string, string> _mappings = new(StringComparer.OrdinalIgnoreCase);
2626

2727
public ExportWorkItemMappingTool(
2828
IOptions<ExportWorkItemMappingToolOptions> options,
@@ -53,7 +53,6 @@ public void AddMapping(string sourceId, string targetId)
5353
return;
5454
}
5555
Log.LogDebug("Source work item ID '{sourceId}' is mapped to target work item ID '{targetId}'.", sourceId, targetId);
56-
_mappings[sourceId] = targetId;
5756
}
5857

5958
/// <summary>
@@ -125,7 +124,7 @@ private Dictionary<string, string> MergeWithExistingMappings(
125124
IDictionary<string, string> mappings,
126125
IDictionary<string, string> existingMappings)
127126
{
128-
Dictionary<string, string> result = new(mappings);
127+
Dictionary<string, string> result = new(mappings, StringComparer.OrdinalIgnoreCase);
129128

130129
foreach (KeyValuePair<string, string> existingMapping in existingMappings)
131130
{

0 commit comments

Comments
 (0)