pcgeek86 / PSGitHub

This PowerShell module contains commands to manage GitHub through its REST API.
MIT License
186 stars 37 forks source link

Get-GitHubAuthenticatedUser throws #6

Closed eloekset closed 8 years ago

eloekset commented 8 years ago

...on Invoke-RestMethod. Cannot send a content-body with this verb-type. 2016-03-20_11-25-37

I've found that this is normal behavior of .NET if trying to invoke a GET method with a request body http://stackoverflow.com/a/3981584/1421847. I'll send a PR that checks whether $Body is null or empty before adding it to the @ApiRequest hash table.

pcgeek86 commented 8 years ago

@eloekset Great idea, thank you for finding that and submitting the PR. Merging now.

pcgeek86 commented 8 years ago

PR has been merged. :)