Fix several conventional and consistency issues.