Syntax corrections and code reformat.