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

Remove omitempty from Content field of RepositoryContentFileOptions #2430

merged 1 commit into from Aug 2, 2022


Copy link

fixes #2427

This removes omitempty from RepositoryContentFileOptions.Content so that an empty content field can be passed in to generate empty files. Before, the content field was omitted, which caused the GitHub API to not accept the request as the field is required, even if it is empty.

Copy link

google-cla bot commented Aug 2, 2022

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

Copy link

codecov bot commented Aug 2, 2022

Codecov Report

Merging #2430 (5498f4f) into master (3a432d6) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #2430   +/-   ##
  Coverage   98.06%   98.06%           
  Files         120      120           
  Lines       10558    10558           
  Hits        10354    10354           
  Misses        140      140           
  Partials       64       64           
Impacted Files Coverage Δ
github/repos_contents.go 89.33% <ø> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

gmlewis approved these changes Aug 2, 2022
Copy link

@gmlewis gmlewis left a comment

Choose a reason for hiding this comment

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

Thank you, @Ashvin-Ranjan !

@gmlewis gmlewis merged commit aff6c4b into google:master Aug 2, 2022
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet

Successfully merging this pull request may close these issues.

Unable to create empty file
3 participants