Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,15 @@ protected virtual async Task<AppCredentials> BuildCredentialsAsync(string appId,

private static T GetBodyContent<T>(string content)
{
return JsonConvert.DeserializeObject<T>(content);
try
{
return JsonConvert.DeserializeObject<T>(content);
}
catch (JsonException)
{
// This will only happen when the skill didn't return valid json in the content (e.g. when the status code is 500 or there's a bug in the skill)
return default;
}
}

private async Task<InvokeResponse<T>> SecurePostActivityAsync<T>(Uri toUrl, Activity activity, string token, CancellationToken cancellationToken)
Expand Down