diff --git a/src/tech/avroid/api/Gitea.groovy b/src/tech/avroid/api/Gitea.groovy index a30e4f0..5dd9546 100644 --- a/src/tech/avroid/api/Gitea.groovy +++ b/src/tech/avroid/api/Gitea.groovy @@ -19,14 +19,14 @@ class Gitea implements Serializable { //TODO: refactor with Gitea token /** * Create new branch from source branch - * @param srcBranch String - source branch + * @param srcRef String - source branch/tag/commit * @param dstBranch String - new branch * @return Boolean - success or failure create */ - public Boolean createBranch(String srcBranch, String dstBranch) { + public Boolean createBranch(String srcRef, String dstBranch) { Map body = [ new_branch_name: dstBranch, - old_branch_name: srcBranch + old_ref_name: srcRef ] Object res = script.httpRequest(