FIX repo instance method's bug

This commit is contained in:
Jasder 2020-09-11 10:13:54 +08:00
parent 9568523286
commit 2e0d76575c
1 changed files with 3 additions and 2 deletions

View File

@ -40,13 +40,14 @@ class Ci::Repo < Ci::RemoteBase
repo_protected: false,
repo_synced: 0,
repo_version: 1,
repo_signer: generate_code,
repo_secret: generate_code,
repo_timeout: 60,
repo_config: '.trustie-pipeline.yml',
repo_created: Time.now.to_i,
repo_updated: Time.now.to_i
)
repo.repo_signer = repo.generate_code
repo.repo_secret = repo.generate_code
if repo.save!
Ci::Perm.auto_create!(user, repo)
repo