Changes to code to remove warnings.