Added additional arguement checks