diff --git a/source/Nuke.Tooling/SettingsEntity.NewInstance.cs b/source/Nuke.Tooling/SettingsEntity.NewInstance.cs index 0cacf3202..fb79a2e39 100644 --- a/source/Nuke.Tooling/SettingsEntity.NewInstance.cs +++ b/source/Nuke.Tooling/SettingsEntity.NewInstance.cs @@ -2,11 +2,11 @@ // Distributed under the MIT License. // https://github.com/nuke-build/nuke/blob/master/LICENSE -using JetBrains.Annotations; using System; using System.IO; using System.Linq; using System.Runtime.Serialization.Formatters.Binary; +using JetBrains.Annotations; #pragma warning disable SYSLIB0011 namespace Nuke.Common.Tooling; @@ -25,12 +25,12 @@ public static T NewInstance(this T settingsEntity) binaryFormatter.Serialize(memoryStream, settingsEntity); memoryStream.Seek(offset: 0, loc: SeekOrigin.Begin); - var newInstance = (T)binaryFormatter.Deserialize(memoryStream); + var newInstance = (T) binaryFormatter.Deserialize(memoryStream); if (newInstance is ToolSettings toolSettings) { - toolSettings.ProcessArgumentConfigurator = ((ToolSettings)(object)settingsEntity).ProcessArgumentConfigurator; - toolSettings.ProcessLogger = ((ToolSettings)(object)settingsEntity).ProcessLogger; - toolSettings.ProcessExitHandler = ((ToolSettings)(object)settingsEntity).ProcessExitHandler; + toolSettings.ProcessArgumentConfigurator = ((ToolSettings) (object) settingsEntity).ProcessArgumentConfigurator; + toolSettings.ProcessLogger = ((ToolSettings) (object) settingsEntity).ProcessLogger; + toolSettings.ProcessExitHandler = ((ToolSettings) (object) settingsEntity).ProcessExitHandler; } return newInstance;