diff options
author | Rémy Coutable <remy@rymai.me> | 2016-12-16 17:44:22 +0100 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2016-12-19 17:35:51 +0100 |
commit | ab06313c36fc5856b2472d3dfcb966a8c6341d0b (patch) | |
tree | ea6d499de443ada8364337c194e1d08b4e28682f /lib/gitlab/github_import/importer.rb | |
parent | e046e4c14d06a19cc30a679f4943c77b56ee6d0c (diff) | |
download | gitlab-ce-ab06313c36fc5856b2472d3dfcb966a8c6341d0b.tar.gz |
Add Project#gitea_import?22348-gitea-importer
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'lib/gitlab/github_import/importer.rb')
-rw-r--r-- | lib/gitlab/github_import/importer.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/gitlab/github_import/importer.rb b/lib/gitlab/github_import/importer.rb index c53cd1a928d..ec1318ab33c 100644 --- a/lib/gitlab/github_import/importer.rb +++ b/lib/gitlab/github_import/importer.rb @@ -22,7 +22,7 @@ module Gitlab opts = {} # Gitea plan to be GitHub compliant - if project.import_type == 'gitea' + if project.gitea_import? uri = URI.parse(project.import_url) host = "#{uri.scheme}://#{uri.host}:#{uri.port}#{uri.path}".sub(%r{/?[\w-]+/[\w-]+\.git\z}, '') opts = { @@ -53,7 +53,7 @@ module Gitlab # Gitea doesn't have a Release API yet # See https://github.com/go-gitea/gitea/issues/330 - unless project.import_type == 'gitea' + unless project.gitea_import? import_releases end @@ -141,7 +141,7 @@ module Gitlab merge_request = gh_pull_request.create! # Gitea doesn't return PR in the Issue API endpoint, so labels must be assigned at this stage - if project.import_type == 'gitea' + if project.gitea_import? apply_labels(merge_request, raw) end rescue => e |