Skip to content

Commit

Permalink
Merge pull request #16 from DEFRA/FixedMissingSenstiveData
Browse files Browse the repository at this point in the history
Updated Contact details to be sensitive, so they are redacted
  • Loading branch information
t11omas authored Dec 12, 2024
2 parents 89ea62d + 97c28f1 commit 33cf6d3
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,15 @@ public static void RegisterIpaffsEnumMaps()

public static void RegisterIpaffsClassMaps()
{
GeneratorClassMap.RegisterClassMap("ContactDetails",
map =>
{
map.MapProperty("name").IsSensitive();
map.MapProperty("telephone").IsSensitive();
map.MapProperty("email").IsSensitive();
map.MapProperty("agent").IsSensitive();
});

GeneratorClassMap.RegisterClassMap("Decision",
map =>
{
Expand Down
5 changes: 5 additions & 0 deletions Btms.Types.Ipaffs.V1/ContactDetails.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@

using System.Text.Json.Serialization;
using System.Dynamic;
using Btms.SensitiveData;


namespace Btms.Types.Ipaffs;
Expand All @@ -25,27 +26,31 @@ public partial class ContactDetails //
/// Name of designated contact
/// </summary>
[JsonPropertyName("name")]
[SensitiveData]
public string? Name { get; set; }


/// <summary>
/// Telephone number of designated contact
/// </summary>
[JsonPropertyName("telephone")]
[SensitiveData]
public string? Telephone { get; set; }


/// <summary>
/// Email address of designated contact
/// </summary>
[JsonPropertyName("email")]
[SensitiveData]
public string? Email { get; set; }


/// <summary>
/// Name of agent representing designated contact
/// </summary>
[JsonPropertyName("agent")]
[SensitiveData]
public string? Agent { get; set; }

}
Expand Down

0 comments on commit 33cf6d3

Please sign in to comment.