Make sure the parameter passed is of correct type