-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Implement rename branch API #32433
base: main
Are you sure you want to change the base?
Implement rename branch API #32433
Conversation
Co-authored-by: sillyguodong <[email protected]>
1beebeb
to
36829ec
Compare
} | ||
|
||
branchName := opt.Name | ||
if branchName != "" { |
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.
How about return error if branchName is empty?
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.
Since this is now a PATCH request I didn't know if it would be alright having the name
field be required.
Then again it is the only field that I could think of that could be updated for a branch, so it maybe make more sense to make it required
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.
I think so.
Resolves #22526.
Builds upon #23061.