Code style refactor and supressing warnings.