Fixed error on cookie not existing.