removing some globals