Removing the Warning and Fix null parameters

Removing the Warning and Fix null parameters