diff --git a/generators/dotnet-templates/Microsoft.BotFramework.CSharp.CoreBot/content/CoreBot/Bots/DialogAndWelcomeBot.cs b/generators/dotnet-templates/Microsoft.BotFramework.CSharp.CoreBot/content/CoreBot/Bots/DialogAndWelcomeBot.cs index 2e0fee0fa8..53b138e630 100644 --- a/generators/dotnet-templates/Microsoft.BotFramework.CSharp.CoreBot/content/CoreBot/Bots/DialogAndWelcomeBot.cs +++ b/generators/dotnet-templates/Microsoft.BotFramework.CSharp.CoreBot/content/CoreBot/Bots/DialogAndWelcomeBot.cs @@ -52,7 +52,7 @@ private Attachment CreateAdaptiveCardAttachment() return new Attachment() { ContentType = "application/vnd.microsoft.card.adaptive", - Content = JsonConvert.DeserializeObject(adaptiveCard), + Content = JsonConvert.DeserializeObject(adaptiveCard, new JsonSerializerSettings { MaxDepth = null }), }; } } diff --git a/generators/dotnet-templates/Microsoft.BotFramework.CSharp.CoreBot/content/CoreBot/CognitiveModels/FlightBooking.cs b/generators/dotnet-templates/Microsoft.BotFramework.CSharp.CoreBot/content/CoreBot/CognitiveModels/FlightBooking.cs index fbb835bb3e..0e7922e036 100644 --- a/generators/dotnet-templates/Microsoft.BotFramework.CSharp.CoreBot/content/CoreBot/CognitiveModels/FlightBooking.cs +++ b/generators/dotnet-templates/Microsoft.BotFramework.CSharp.CoreBot/content/CoreBot/CognitiveModels/FlightBooking.cs @@ -75,7 +75,7 @@ public class _Instance public void Convert(dynamic result) { - var app = JsonConvert.DeserializeObject(JsonConvert.SerializeObject(result, new JsonSerializerSettings { NullValueHandling = NullValueHandling.Ignore })); + var app = JsonConvert.DeserializeObject(JsonConvert.SerializeObject(result, new JsonSerializerSettings { NullValueHandling = NullValueHandling.Ignore, MaxDepth = null })); Text = app.Text; AlteredText = app.AlteredText; Intents = app.Intents; diff --git a/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBot/Bots/DialogAndWelcomeBot.cs b/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBot/Bots/DialogAndWelcomeBot.cs index fc2740d1e6..e83d422dad 100644 --- a/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBot/Bots/DialogAndWelcomeBot.cs +++ b/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBot/Bots/DialogAndWelcomeBot.cs @@ -53,7 +53,7 @@ private Attachment CreateAdaptiveCardAttachment() return new Attachment() { ContentType = "application/vnd.microsoft.card.adaptive", - Content = JsonConvert.DeserializeObject(adaptiveCard), + Content = JsonConvert.DeserializeObject(adaptiveCard, new JsonSerializerSettings { MaxDepth = null }), }; } } diff --git a/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBot/CognitiveModels/FlightBooking.cs b/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBot/CognitiveModels/FlightBooking.cs index 1388b12b39..f2bd6ce849 100644 --- a/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBot/CognitiveModels/FlightBooking.cs +++ b/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBot/CognitiveModels/FlightBooking.cs @@ -75,7 +75,7 @@ public class _Instance public void Convert(dynamic result) { - var app = JsonConvert.DeserializeObject(JsonConvert.SerializeObject(result, new JsonSerializerSettings { NullValueHandling = NullValueHandling.Ignore })); + var app = JsonConvert.DeserializeObject(JsonConvert.SerializeObject(result, new JsonSerializerSettings { NullValueHandling = NullValueHandling.Ignore, MaxDepth = null })); Text = app.Text; AlteredText = app.AlteredText; Intents = app.Intents; diff --git a/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBotWithTests/CoreBot/Bots/DialogAndWelcomeBot.cs b/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBotWithTests/CoreBot/Bots/DialogAndWelcomeBot.cs index 5f0ac4cd78..e2d0ef9e68 100644 --- a/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBotWithTests/CoreBot/Bots/DialogAndWelcomeBot.cs +++ b/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBotWithTests/CoreBot/Bots/DialogAndWelcomeBot.cs @@ -53,7 +53,7 @@ private Attachment CreateAdaptiveCardAttachment() return new Attachment() { ContentType = "application/vnd.microsoft.card.adaptive", - Content = JsonConvert.DeserializeObject(adaptiveCard), + Content = JsonConvert.DeserializeObject(adaptiveCard, new JsonSerializerSettings { MaxDepth = null }), }; } } diff --git a/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBotWithTests/CoreBot/CognitiveModels/FlightBooking.cs b/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBotWithTests/CoreBot/CognitiveModels/FlightBooking.cs index 664880a096..c7d92beeb1 100644 --- a/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBotWithTests/CoreBot/CognitiveModels/FlightBooking.cs +++ b/generators/vsix-vs-win/BotBuilderVSIX-V4/UncompressedProjectTemplates/CoreBotWithTests/CoreBot/CognitiveModels/FlightBooking.cs @@ -75,7 +75,7 @@ public class _Instance public void Convert(dynamic result) { - var app = JsonConvert.DeserializeObject(JsonConvert.SerializeObject(result, new JsonSerializerSettings { NullValueHandling = NullValueHandling.Ignore })); + var app = JsonConvert.DeserializeObject(JsonConvert.SerializeObject(result, new JsonSerializerSettings { NullValueHandling = NullValueHandling.Ignore, MaxDepth = null })); Text = app.Text; AlteredText = app.AlteredText; Intents = app.Intents;