Skip to content

Commit

Permalink
Merge pull request #43 from joepb/fix-unset-body-type
Browse files Browse the repository at this point in the history
Fix null reference error when body.type is not set
  • Loading branch information
EricSmekens authored Jan 31, 2022
2 parents e0b5598 + a183215 commit b8e39ec
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## Unreleased
- Fix failure on body.type set to null
- Add support for a custom end point URI

## [2.3.0] - 2021-10-27
Expand Down
2 changes: 1 addition & 1 deletion CM.Text/BusinessMessaging/Model/Body.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public class Body
/// You can limit the number of parts by setting the maximum number of message parts.
/// <see cref="Message.MaximumNumberOfMessageParts" />
/// </summary>
[JsonProperty("type")]
[JsonProperty("type", DefaultValueHandling = DefaultValueHandling.Ignore)]
public string Type { get; set; }
}
}

0 comments on commit b8e39ec

Please sign in to comment.