소스 검색

Make repo creation for API similar to UI (#6142)

tags/v1.9.0-dev
John Olheiser 5 년 전
부모
커밋
df30010dbd
1개의 변경된 파일3개의 추가작업 그리고 0개의 파일을 삭제
  1. 3
    0
      routers/api/v1/repo/repo.go

+ 3
- 0
routers/api/v1/repo/repo.go 파일 보기

@@ -213,6 +213,9 @@ func Search(ctx *context.APIContext) {

// CreateUserRepo create a repository for a user
func CreateUserRepo(ctx *context.APIContext, owner *models.User, opt api.CreateRepoOption) {
if opt.AutoInit && opt.Readme == "" {
opt.Readme = "Default"
}
repo, err := models.CreateRepository(ctx.User, owner, models.CreateRepoOptions{
Name: opt.Name,
Description: opt.Description,

Loading…
취소
저장