public UpdateAsync ( string surveyId, Language language ) : System.Threading.Tasks.Task | ||
surveyId | string | |
language | Language | |
return | System.Threading.Tasks.Task |
public Task UpdateAsync(string surveyId, Language language)
{
CheckSurveyId(surveyId);
if (language == null)
{
throw new ArgumentNullException("language");
}
return Client.PutAsJsonAsync(LanguagesApi(surveyId, 0).AbsoluteUri,
language).FlattenExceptions();
}
public void TestUpdateAsync_SurveyIdIsNull_Throws() { var target = new NfieldLanguagesService(); Assert.Throws<ArgumentNullException>(() => UnwrapAggregateException(target.UpdateAsync(null, new Language()))); }