Raising error when required parameter is missing