From d1ef0b091f231d3ce9495d6004fc4765e81dab4f Mon Sep 17 00:00:00 2001 From: Dinh Tran Date: Mon, 11 Mar 2024 13:39:59 +0700 Subject: [PATCH] Backporting for dotnet 6 --- .../Api/UnknownEndpointTypeException.cs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/Umbraco.Commerce.PaymentProviders.Opayo/Api/UnknownEndpointTypeException.cs b/src/Umbraco.Commerce.PaymentProviders.Opayo/Api/UnknownEndpointTypeException.cs index fa3cb75..97291a2 100644 --- a/src/Umbraco.Commerce.PaymentProviders.Opayo/Api/UnknownEndpointTypeException.cs +++ b/src/Umbraco.Commerce.PaymentProviders.Opayo/Api/UnknownEndpointTypeException.cs @@ -1,13 +1,12 @@ using System; using System.Globalization; -using System.Text; namespace Umbraco.Commerce.PaymentProviders.Opayo.Api { [Serializable] public class UnknownEndpointTypeException : Exception { - private static readonly CompositeFormat _messageTemplate = CompositeFormat.Parse("Unknown endpoint type '{0}'"); + private const string MessageTemplate = "Unknown endpoint type '{0}'"; public UnknownEndpointTypeException() : base("Unknown endpoint type") @@ -15,7 +14,7 @@ public UnknownEndpointTypeException() } public UnknownEndpointTypeException(string endpointType) - : base(string.Format(CultureInfo.InvariantCulture, _messageTemplate, endpointType)) + : base(string.Format(CultureInfo.InvariantCulture, MessageTemplate, endpointType)) { }