Fixes bug in delete cookie function

deleteCookie had a bad reference from previous implementation.