Category error


https://forum.kartris.com/Topic3056.aspx
Print Topic | Close Window

By TheCalicoTree - Thu 15 May 2014
Since we upgraded to 2.5009 we have been unable to edit categories. The following error is logged:

-----------------------------------------------------------------------------
>> CategoriesBLL._UpdateCategoryHierarchy
-----------------------------------------------------------------------------
>> System.NullReferenceException
>> 5/15/2014 10:00:42 AM
>> Version:2.5009
>> URL:http://www.hotel-buyer-store.co.uk/Admin/_ModifyCategory.aspx?CategoryID=80&strParent=19
>> 81.111.151.133
>> CUSTOM MESSAGE:
Error: An unknown error has occurred. Please check the error logs for any info.
>> MESSAGE:
Object reference not set to an instance of an object.
>> STACK:
at CategoriesBLL._UpdateCategoryHierarchy(Int32 pChildID, String pNewParents, SqlConnection sqlConn, SqlTransaction savePoint)

I can see a record in tblKartrisCategories, CAT_ID - 0 and it has NULL values. It is also in the CategoryHierarchy table as a parent of all top level categories.

I don't know whether this has always been there and am reluctant to delete it to see if the problem is removed.

Any suggestions?
By BORNXenon - Thu 15 May 2014
Not sure if this is the same problem or not, but I have noticed that if a Category has a parent category, then I am unable to edit the SEO fields and get a pop-up saying an unknown error has occurred.

If I remove the parent category, I can then edit the SEO fields successfully and then have to put the parent category back.
By TheCalicoTree - Wed 21 May 2014
Thanks BornXenon, it looks like it is the same problem. It is not a problem for parent categories and with subcategories, if their parent is removed we are able to save.

This seems to be an error introduced in 2.5009. I have the same error on two separate sites.

Kartris - will this be resolved in next release?
By TheCalicoTree - Wed 11 Jun 2014
So it looks as though this was a bug that has now been resolved in 2.6003. We plan to upgrade soon so I will mark this as the resolution.
By Paul - Thu 12 Jun 2014
Yes, just to clarify, it worked if you changed the parent categories (either by removing or adding one), but not if you left them the same (I think this was the case for top level cats too). It is fixed in 2.6003.