Slightly different patch to fix the auto save cart functionality for anonymous user reported by Mirko on OFBIZ-5157.