Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set-GitHubRepositoryTopic: Fix Exception When Clear 'Parameter' is Specified #216

Merged
merged 2 commits into from
Jun 2, 2020
Merged

Set-GitHubRepositoryTopic: Fix Exception When Clear 'Parameter' is Specified #216

merged 2 commits into from
Jun 2, 2020

Conversation

X-Guardian
Copy link
Contributor

@X-Guardian X-Guardian commented Jun 2, 2020

Description

This PR fixes the exception in the Set-GithubRepositoryTopic function when the Clear parameter is specified.

Issues Fixed

References

https://developer.github.com/v3/repos/#replace-all-repository-topics - Send an empty array ([]) to clear all topics from the repository.

Checklist

  • You actually ran the code that you just wrote, especially if you did just "one last quick change".
  • Comment-based help added/updated, including examples.
  • Static analysis
    is reporting back clean.
  • New/changed code adheres to our coding guidelines.
  • Changes to the manifest file follow the manifest guidance.
  • Unit tests were added/updated and are all passing. See testing guidelines.
  • Relevant usage examples have been added/updated in USAGE.md.
  • If desired, ensure your name is added to our Contributors list

Copy link
Member

@HowardWolosky HowardWolosky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Super minor formatting change request, and then this is good to go.
Thanks so much for jumping on this fix so quickly! Glad we have a UT coming in via #176 for this.

GitHubRepositories.ps1 Outdated Show resolved Hide resolved
Co-authored-by: Howard Wolosky <HowardWolosky@users.noreply.github.com>
@X-Guardian X-Guardian marked this pull request as ready for review June 2, 2020 19:56
@HowardWolosky HowardWolosky merged commit d1bd976 into microsoft:master Jun 2, 2020
@X-Guardian X-Guardian deleted the Set-GitHubRepositoryTopic-Clear-Fix branch June 9, 2020 23:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Set-GitHubRepositoryTopic: Exception When 'Clear' Parameter is Specified
2 participants