more case handling in cookie reading