/// <summary> /// Updates a label. /// </summary> /// <remarks> /// See the <a href="http://developer.github.com/v3/issues/labels/#update-a-label">API documentation</a> for more information. /// </remarks> /// <param name="repositoryId">The Id of the repository</param> /// <param name="labelName">The name of the label</param> /// <param name="labelUpdate">The data for the label to be updated</param> public Task <Label> Update(long repositoryId, string labelName, LabelUpdate labelUpdate) { Ensure.ArgumentNotNullOrEmptyString(labelName, "labelName"); Ensure.ArgumentNotNull(labelUpdate, "labelUpdate"); return(ApiConnection.Post <Label>(ApiUrls.Label(repositoryId, labelName), labelUpdate)); }
/// <summary> /// Updates a label. /// </summary> /// <remarks> /// See the <a href="http://developer.github.com/v3/issues/labels/#update-a-label">API documentation</a> for more information. /// </remarks> /// <param name="repositoryId">The Id of the repository</param> /// <param name="labelName">The name of the label</param> /// <param name="labelUpdate">The data for the label to be updated</param> public Task <Label> Update(long repositoryId, string labelName, LabelUpdate labelUpdate) { Ensure.ArgumentNotNullOrEmptyString(labelName, nameof(labelName)); Ensure.ArgumentNotNull(labelUpdate, nameof(labelUpdate)); return(ApiConnection.Post <Label>(ApiUrls.Label(repositoryId, labelName), labelUpdate, AcceptHeaders.LabelsApiPreview)); }
/// <summary> /// Updates a label. /// </summary> /// <remarks> /// See the <a href="http://developer.github.com/v3/issues/labels/#update-a-label">API documentation</a> for more information. /// </remarks> /// <param name="owner">The owner of the repository</param> /// <param name="name">The name of the repository</param> /// <param name="labelName">The name of the label</param> /// <param name="labelUpdate">The data for the label to be updated</param> public Task <Label> Update(string owner, string name, string labelName, LabelUpdate labelUpdate) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); Ensure.ArgumentNotNullOrEmptyString(name, "name"); Ensure.ArgumentNotNullOrEmptyString(labelName, "labelName"); Ensure.ArgumentNotNull(labelUpdate, "labelUpdate"); return(ApiConnection.Post <Label>(ApiUrls.Label(owner, name, labelName), labelUpdate)); }
public Task <Label> Update(long repositoryId, string labelName, LabelUpdate labelUpdate) { Ensure.ArgumentNotNullOrEmptyString(labelName, nameof(labelName)); Ensure.ArgumentNotNull(labelUpdate, nameof(labelUpdate)); // BUG: this should be a PATCH instead of POST return(ApiConnection.Post <Label>(ApiUrls.Label(repositoryId, labelName), labelUpdate)); }
/// <summary> /// Updates a label. /// </summary> /// <remarks> /// See the <a href="http://developer.github.com/v3/issues/labels/#update-a-label">API documentation</a> for more information. /// </remarks> /// <param name="owner">The owner of the repository</param> /// <param name="name">The name of the repository</param> /// <param name="labelName">The name of the label</param> /// <param name="labelUpdate">The data for the label to be updated</param> public Task <Label> Update(string owner, string name, string labelName, LabelUpdate labelUpdate) { Ensure.ArgumentNotNullOrEmptyString(owner, nameof(owner)); Ensure.ArgumentNotNullOrEmptyString(name, nameof(name)); Ensure.ArgumentNotNullOrEmptyString(labelName, nameof(labelName)); Ensure.ArgumentNotNull(labelUpdate, nameof(labelUpdate)); return(ApiConnection.Post <Label>(ApiUrls.Label(owner, name, labelName), labelUpdate, AcceptHeaders.LabelsApiPreview)); }
public Task <Label> Update(string owner, string name, string labelName, LabelUpdate labelUpdate) { Ensure.ArgumentNotNullOrEmptyString(owner, nameof(owner)); Ensure.ArgumentNotNullOrEmptyString(name, nameof(name)); Ensure.ArgumentNotNullOrEmptyString(labelName, nameof(labelName)); Ensure.ArgumentNotNull(labelUpdate, nameof(labelUpdate)); // BUG: this should be a PATCH instead of POST return(ApiConnection.Post <Label>(ApiUrls.Label(owner, name, labelName), labelUpdate)); }
/// <summary> /// Updates a label. /// </summary> /// <remarks> /// See the <a href="http://developer.github.com/v3/issues/labels/#update-a-label">API documentation</a> for more information. /// </remarks> /// <param name="repositoryId">The Id of the repository</param> /// <param name="labelName">The name of the label</param> /// <param name="labelUpdate">The data for the label to be updated</param> public Task<Label> Update(int repositoryId, string labelName, LabelUpdate labelUpdate) { Ensure.ArgumentNotNullOrEmptyString(labelName, "labelName"); Ensure.ArgumentNotNull(labelUpdate, "labelUpdate"); return ApiConnection.Post<Label>(ApiUrls.Label(repositoryId, labelName), labelUpdate); }
/// <summary> /// Updates a label. /// </summary> /// <remarks> /// See the <a href="http://developer.github.com/v3/issues/labels/#update-a-label">API documentation</a> for more information. /// </remarks> /// <param name="owner">The owner of the repository</param> /// <param name="name">The name of the repository</param> /// <param name="labelName">The name of the label</param> /// <param name="labelUpdate">The data for the label to be updated</param> public Task<Label> Update(string owner, string name, string labelName, LabelUpdate labelUpdate) { Ensure.ArgumentNotNullOrEmptyString(owner, "owner"); Ensure.ArgumentNotNullOrEmptyString(name, "name"); Ensure.ArgumentNotNullOrEmptyString(labelName, "labelName"); Ensure.ArgumentNotNull(labelUpdate, "labelUpdate"); return ApiConnection.Post<Label>(ApiUrls.Label(owner, name, labelName), labelUpdate); }