mirror of
https://github.com/microsoft/PowerToys.git
synced 2024-12-19 06:14:11 +08:00
ArgumentNullException.ThrowIfNull in Helper
This commit is contained in:
parent
e504ddbe2f
commit
5d1c3e6d2d
@ -114,11 +114,8 @@ namespace Microsoft.PowerToys.Settings.UI.Library.Utilities
|
||||
{
|
||||
// Split up the version strings into int[]
|
||||
// Example: v10.0.2 -> {10, 0, 2};
|
||||
if (version1 == null)
|
||||
{
|
||||
throw new ArgumentNullException(nameof(version1));
|
||||
}
|
||||
else ArgumentNullException.ThrowIfNull(version2);
|
||||
ArgumentNullException.ThrowIfNull(version1);
|
||||
ArgumentNullException.ThrowIfNull(version2);
|
||||
|
||||
var v1 = version1.Substring(1).Split('.').Select(int.Parse).ToArray();
|
||||
var v2 = version2.Substring(1).Split('.').Select(int.Parse).ToArray();
|
||||
|
Loading…
Reference in New Issue
Block a user