#2: fixes the bug that Could not remove cookie