From 1dc62ae3fd1e777a086fda203032e3f7b3862d77 Mon Sep 17 00:00:00 2001 From: Azuk 443 Date: Sat, 18 Nov 2023 13:20:10 +0800 Subject: [PATCH] TEST: test if Convert.ToHexString works without if-def --- .../src/System/Security/Cryptography/Xml/Utils.cs | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/libraries/System.Security.Cryptography.Xml/src/System/Security/Cryptography/Xml/Utils.cs b/src/libraries/System.Security.Cryptography.Xml/src/System/Security/Cryptography/Xml/Utils.cs index ffffeefa5bac3..38f21e49db927 100644 --- a/src/libraries/System.Security.Cryptography.Xml/src/System/Security/Cryptography/Xml/Utils.cs +++ b/src/libraries/System.Security.Cryptography.Xml/src/System/Security/Cryptography/Xml/Utils.cs @@ -720,17 +720,10 @@ internal static X509Certificate2Collection BuildBagOfCerts(KeyInfoX509Data keyIn return collection; } -#if NET5_0_OR_GREATER internal static string EncodeHexString(byte[] sArray) { return Convert.ToHexString(sArray); } -#else - internal static string EncodeHexString(byte[] sArray) - { - return HexConverter.ToString(sArray); - } -#endif internal static byte[] DecodeHexString(string s) {