now make sure global variables are cleared