Fixed some typos and data type mismatches