Browse Source

Small cleanups and fixups

4.0.0-beta
Anairkoen Schno 4 years ago
parent
commit
9a666fa73b
3 changed files with 7 additions and 2 deletions
  1. +1
    -1
      IPA.Loader/Logging/Logger.cs
  2. +1
    -1
      IPA.Loader/Logging/StandardLogger.cs
  3. +5
    -0
      IPA.Loader/Utilities/Utils.cs

+ 1
- 1
IPA.Loader/Logging/Logger.cs View File

@ -171,7 +171,7 @@ namespace IPA.Logging
/// <summary>
/// Used for when the level is undefined.
/// </summary>
Undefined = Byte.MaxValue
Undefined = byte.MaxValue
}
/// <summary>


+ 1
- 1
IPA.Loader/Logging/StandardLogger.cs View File

@ -128,7 +128,7 @@ namespace IPA.Logging
logName = $"{parent.logName}/{subName}";
this.parent = parent;
printers = new List<LogPrinter>();
if (SelfConfig.Debug_.CondenseModLogs_)
if (!SelfConfig.Debug_.CondenseModLogs_)
printers.Add(new PluginSubLogPrinter(parent.logName, subName));
if (logThread == null || !logThread.IsAlive)


+ 5
- 0
IPA.Loader/Utilities/Utils.cs View File

@ -4,6 +4,7 @@ using System.Text;
using System.Linq;
using System.Collections.Generic;
using Mono.Cecil;
using System.Runtime.CompilerServices;
#if NET3
using File = Net3_Proxy.File;
#endif
@ -197,11 +198,15 @@ namespace IPA.Utilities
}
#if NET4
[MethodImpl(MethodImplOptions.AggressiveInlining)]
internal static IEnumerable<string> StrJP(this IEnumerable<string> a) => a;
[MethodImpl(MethodImplOptions.AggressiveInlining)]
internal static IEnumerable<string> StrJP<T>(this IEnumerable<T> a) => a.Select(o => $"{o}" /* safer than .ToString() */);
#endif
#if NET3
[MethodImpl(MethodImplOptions.AggressiveInlining)]
internal static string[] StrJP(this IEnumerable<string> a) => a.ToArray();
[MethodImpl(MethodImplOptions.AggressiveInlining)]
internal static string[] StrJP<T>(this IEnumerable<T> a) => a.Select(o => $"{o}" /* safer than .ToString() */).ToArray();
#endif
}


Loading…
Cancel
Save