Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
feat: add ability to add checks with app ids #1844
feat: add ability to add checks with app ids #1844
Changes from 4 commits
c8c7b30
33e1ccb
47314dd
3882581
3d5196f
6819f35
995bee2
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
Check warning on line 55 in src/main/java/org/kohsuke/github/GHBranchProtectionBuilder.java
src/main/java/org/kohsuke/github/GHBranchProtectionBuilder.java#L55
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggest something like this:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apparently the deprecated API can be implemented in the new API. From the docs:
![image](https://private-user-images.githubusercontent.com/61763026/339414047-ce489ff9-da66-41fc-9224-369a1b205039.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjAwNDU2MzUsIm5iZiI6MTcyMDA0NTMzNSwicGF0aCI6Ii82MTc2MzAyNi8zMzk0MTQwNDctY2U0ODlmZjktZGE2Ni00MWZjLTkyMjQtMzY5YTFiMjA1MDM5LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MDMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzAzVDIyMjIxNVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWZlMDI3MzJmNGE4ZjE2NjY5ZmYzNWFjODFlNDU2MTk2ZThhNmNiN2Y0MTVkNjJlZmJkMTYwYjE5ZWE0ZTE3YWQmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.Ey0-MccHWUAELUDQ8PL7kIvDn8Mm0WEljfRunwKeG6o)
I underlined the same logic between the old and new API.
I.e. you need to omit the
app_id
field to do it the old way. I've added the@JsonInclude(JsonInclude.Include.NON_NULL)
to instruct jackson to omit it in that case, and a comment explaining the special "app_id" values.So I committed a change which allows the use of both the old and new user methods at the same time, preserving both their effects.
How does that look to you?