Skip to content

Commit abe9116

Browse files
authored
Merge pull request #49 from dynamicweb/dbe/24631-LiveShippingFeeProvider.cs-GetShipping()
Fix LiveShippingFeeProvider.cs GetShipping()
2 parents f4378b5 + 692adde commit abe9116

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/Dynamicweb.Ecommerce.DynamicwebLiveIntegration/Dynamicweb.Ecommerce.DynamicwebLiveIntegration.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
3-
<Version>10.4.24</Version>
3+
<Version>10.4.25</Version>
44
<AssemblyVersion>1.0.0.0</AssemblyVersion>
55
<Title>Live Integration</Title>
66
<Description>Live Integration</Description>

src/Dynamicweb.Ecommerce.DynamicwebLiveIntegration/LiveShippingFeeProvider.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
using Dynamicweb.Ecommerce.DynamicwebLiveIntegration.Logging;
44
using Dynamicweb.Ecommerce.Orders;
55
using Dynamicweb.Ecommerce.Prices;
6+
using Dynamicweb.Extensibility;
67
using Dynamicweb.Extensibility.AddIns;
78
using System;
89
using System.Linq;
@@ -69,7 +70,9 @@ private static void AddToCache(Order order, double shippingFee)
6970
/// <returns>Shipping.</returns>
7071
private static Shipping GetShipping()
7172
{
72-
return Services.Shippings.GetShippingsWithoutRegions(false).FirstOrDefault(s => !string.IsNullOrEmpty(s.ServiceSystemName) && string.Compare(s.ServiceSystemName, typeof(LiveShippingFeeProvider).FullName, StringComparison.OrdinalIgnoreCase) == 0);
73+
return Services.Shippings.GetShippingsWithoutRegions(false).FirstOrDefault(s => !string.IsNullOrEmpty(s.ServiceSystemName) &&
74+
(string.Equals(typeof(LiveShippingFeeProvider).GetTypeNameWithAssembly(), s.ServiceSystemName) ||
75+
string.Equals(s.ServiceSystemName, typeof(LiveShippingFeeProvider).FullName, StringComparison.OrdinalIgnoreCase)));
7376
}
7477

7578
private static void ProcessLiveIntegrationShipping(Settings settings, Order order, XmlNode orderNode, Logger logger)

0 commit comments

Comments
 (0)