fixed errors with static variable initialization