From 1d28714d565adfe4d09dc343d78721d2ed58f770 Mon Sep 17 00:00:00 2001 From: Alexander Hjelm Date: Wed, 4 Oct 2023 16:23:11 +0200 Subject: [PATCH] Fix for User-type fields on first revision --- src/WorkItemMigrator/JiraExport/JiraItem.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/WorkItemMigrator/JiraExport/JiraItem.cs b/src/WorkItemMigrator/JiraExport/JiraItem.cs index d87ada3d..425c43c1 100644 --- a/src/WorkItemMigrator/JiraExport/JiraItem.cs +++ b/src/WorkItemMigrator/JiraExport/JiraItem.cs @@ -486,6 +486,13 @@ private static Dictionary ExtractFields(string key, JObject remo { value = prop.Value.Value(); } + // User picker + else if (type == JTokenType.Object && prop.Value["accountId"] != null + && prop.Value["emailAddress"] != null && prop.Value["avatarUrls"] != null + && prop.Value["displayName"] != null) + { + value = prop.Value["accountId"].ToString(); + } else if (prop.Value.Type == JTokenType.Date) { value = prop.Value.Value();