Fixed issues with initialization.