mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-02 19:30:48 +08:00
更改:触发任务判断为失败条件
This commit is contained in:
@@ -14,7 +14,7 @@ class TouchSyncJob < ApplicationJob
|
|||||||
else
|
else
|
||||||
result = Reposync::SyncBranchService.call(sync_repository.repo_name, touchable.external_branch_name, sync_repository.sync_direction)
|
result = Reposync::SyncBranchService.call(sync_repository.repo_name, touchable.external_branch_name, sync_repository.sync_direction)
|
||||||
end
|
end
|
||||||
if result.is_a?(Array)
|
if result.is_a?(Array) && result[0].to_i == 0
|
||||||
touchable.update_attributes!({sync_status: 1, sync_time: Time.now})
|
touchable.update_attributes!({sync_status: 1, sync_time: Time.now})
|
||||||
else
|
else
|
||||||
touchable.update_attributes!({sync_status: 2, sync_time: Time.now})
|
touchable.update_attributes!({sync_status: 2, sync_time: Time.now})
|
||||||
|
|||||||
Reference in New Issue
Block a user