Fixed a few initialization errors