Updated Code to remove all Warnings.