Fixed some small issues.   changed the initialization code