Skip to content

Commit

Permalink
Merge pull request #3 from Immersive-Plugins-Team/config
Browse files Browse the repository at this point in the history
IPT.Common 1.1.1
  • Loading branch information
opus49 committed Jan 1, 2022
2 parents 1a10c36 + 2f43328 commit 316d38c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 11 deletions.
4 changes: 2 additions & 2 deletions IPT.Common/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.1.0.0")]
[assembly: AssemblyFileVersion("1.1.0.0")]
[assembly: AssemblyVersion("1.1.1.0")]
[assembly: AssemblyFileVersion("1.1.1.0")]
12 changes: 3 additions & 9 deletions IPT.Common/User/Configuration.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using IPT.Common.API;
using IPT.Common.User.Inputs;
Expand Down Expand Up @@ -123,16 +122,11 @@ protected void SaveINI(string filename)
private List<Setting> GetAllSettings()
{
var settings = new List<Setting>();
foreach (var field in this.GetType().GetFields(BindingFlags.Public | BindingFlags.Instance).Where(
x => x.FieldType.BaseType == typeof(Setting)))
foreach (var field in this.GetType().GetFields(BindingFlags.Public | BindingFlags.Instance))
{
try
if (field.GetValue(this) is Setting setting)
{
settings.Add((Setting)field.GetValue(this));
}
catch (Exception ex)
{
Logging.Error($"could not retrieve setting: {field.Name}", ex);
settings.Add(setting);
}
}

Expand Down

0 comments on commit 316d38c

Please sign in to comment.