From 641c6c4dddc682b12df49b267964b520012e9beb Mon Sep 17 00:00:00 2001 From: daiao <358551898@qq.com> Date: Mon, 9 Sep 2019 21:24:51 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A7=81=E5=AF=86=E4=BB=93=E5=BA=93=E5=AE=9E?= =?UTF-8?q?=E8=AE=ADfork=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/shixuns_controller.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/shixuns_controller.rb b/app/controllers/shixuns_controller.rb index 8d735c25e..85b724ca9 100644 --- a/app/controllers/shixuns_controller.rb +++ b/app/controllers/shixuns_controller.rb @@ -223,11 +223,11 @@ class ShixunsController < ApplicationController # 同步私密版本库 if @shixun.shixun_secret_repository repo_name = "#{current_user.login}/secret_#{@shixun.identifier}" - secret_repo = "#{current_user.login}/secret_#{@new_shixun.identifier}" + fork_repository_name = "#{current_user.login}/secret_#{@new_shixun.identifier}" ShixunSecretRepository.create!(shixun_id: @new_shixun.id, repo_name: "#{repo_name}", secret_dir_path: @shixun.secret_dir_path) - GitService.fork_repository(repo_path: "#{repo_name}.git", fork_repository_path: (secret_repo + ".git")) + GitService.fork_repository(repo_path: "#{repo_name}.git", fork_repository_path: (fork_repository_name + ".git")) end # 同步镜像