Closed irkush closed 11 years ago
At the moment the GetIpAddress() is located in the sub-classes IndividualCustomer and CompanyCustomer.
This forces an unneccessary cast which can be easily avoided.
if (order.GetIsCompanyIdentity()) { if (order.GetCompanyCustomer().GetIpAddress() != null) { WriteSimpleElement("ipaddress", order.GetCompanyCustomer().GetIpAddress()); } } else { if (order.GetIndividualCustomer().GetIpAddress() != null) { WriteSimpleElement("ipaddress", order.GetIndividualCustomer().GetIpAddress()); } }
Solved in b09f10fbf80d8b0f4db01071e08ea83c72e3c4e0
At the moment the GetIpAddress() is located in the sub-classes IndividualCustomer and CompanyCustomer.
This forces an unneccessary cast which can be easily avoided.