Add check for cookie_hash
More comments