From 98261f4e21029305f14d03914008875b41b63369 Mon Sep 17 00:00:00 2001 From: TekH Date: Mon, 15 Dec 2025 15:05:56 +0100 Subject: [PATCH] Refactor ProfileType to enum in RecActionViewDto Changed ProfileType from string? to ProfileType? enum for improved type safety. Updated URI scheme assignment to use ToUriBuilderScheme(), centralizing scheme mapping logic. --- src/ReC.Application/Common/Dto/RecActionViewDto.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ReC.Application/Common/Dto/RecActionViewDto.cs b/src/ReC.Application/Common/Dto/RecActionViewDto.cs index a5e97ac..d8de787 100644 --- a/src/ReC.Application/Common/Dto/RecActionViewDto.cs +++ b/src/ReC.Application/Common/Dto/RecActionViewDto.cs @@ -10,7 +10,7 @@ public record RecActionViewDto public string? ProfileName { get; init; } - public string? ProfileType { get; init; } + public ProfileType? ProfileType { get; init; } public byte? Sequence { get; init; } @@ -80,8 +80,8 @@ public record RecActionViewDto builder.Port = -1; - if (ProfileType is not null) - builder.Scheme = ProfileType; + if (ProfileType is ProfileType type) + builder.Scheme = type.ToUriBuilderScheme(); return builder; }