Json extension data fody (#340)

* Added a new Fody plugin to add to every model class the JsonExtensionData attribute

* retargeted fody plugin to netstandard for msbuild runtime

* Fixed runtime issue

* Fixed property check for new extension data properties

---------

Co-authored-by: Alex <clodanSPT@hotmail.com>
This commit is contained in:
clodanSPT
2025-06-02 12:15:44 +01:00
committed by GitHub
parent 54fe3cf7c5
commit cab8fa82a2
18 changed files with 262 additions and 47 deletions
@@ -62,12 +62,12 @@ public class LauncherController(
{
var result = new Dictionary<string, string>();
var dbProfiles = _databaseService.GetProfiles();
foreach (var templatesProperty in typeof(ProfileTemplates).GetProperties().Where(p => p.CanWrite))
foreach (var templatesProperty in typeof(ProfileTemplates).GetProperties().Where(p => p.CanWrite && p.Name != "ExtensionData"))
{
var propertyValue = templatesProperty.GetValue(dbProfiles);
if (propertyValue == null)
{
_logger.Warning(_localisationService.GetText("launcher-missing_property", templatesProperty));
_logger.Warning(_localisationService.GetText("launcher-missing_property", templatesProperty.Name));
continue;
}