forked from Gitlink/forgeplus
Merge pull request '解绑流程修改' (#9) from trustie_server into develop
Reviewed-on: https://git.trustie.net/jasder/forgeplus/pulls/9
This commit is contained in:
commit
5cdfc4ba62
|
@ -96,12 +96,14 @@ class Ci::CloudAccountsController < Ci::BaseController
|
|||
|
||||
def unbind
|
||||
ActiveRecord::Base.transaction do
|
||||
unbind_account!
|
||||
if @repos
|
||||
@repos.each do |repo|
|
||||
repo.deactivate!
|
||||
if current_user.ci_cloud_account.server_type == Ci::CloudAccount::SERVER_TYPE_TRUSTIE
|
||||
if @repos
|
||||
@repos.each do |repo|
|
||||
repo.deactivate!
|
||||
end
|
||||
end
|
||||
end
|
||||
unbind_account!
|
||||
render_ok
|
||||
end
|
||||
rescue Exception => ex
|
||||
|
|
Loading…
Reference in New Issue