Mufasa
-
1/27/2009 10:25:12 AM
FIX: SKUPriceDetailControl not checking for nulls
~/CMSEcommerce/ShoppingCart/ShoppingCartSKUPriceDetail.ascx.cs does not check for a null ShoppingCart (in the case the page is directly accessed without the customer going to the shopping cart first, in the case of bots/crawlers mainly) in some places. If it isn't checked, it throws a NullReferenceException.
It is checked in most places, but in Kentico 3.1a still needs checked in the RoundedTotalPrice and GetFormattedSubtotalValue properties.
I just used changed the code for those properties from the use of: this.ShoppingCartInfoObj.CurrencyInfoObj to: this.ShoppingCartInfoObj == null ? CurrencyInfoProvider.GetMainCurrency() : this.ShoppingCartInfoObj.CurrencyInfoObj
|