Updated to correct coding styles as suggested.