Fix URL link in Bitbucket status
This commit is contained in:
parent
3735ce43fc
commit
8377057364
|
@ -52,7 +52,7 @@
|
|||
- @repos.each do |repo|
|
||||
%tr{ id: "repo_#{repo.owner}___#{repo.slug}" }
|
||||
%td
|
||||
= link_to repo.full_name, "https://bitbucket.org/#{repo.full_name}", target: '_blank', rel: 'noopener noreferrer'
|
||||
= link_to repo.full_name, repo.browse_url, target: '_blank', rel: 'noopener noreferrer'
|
||||
%td.import-target
|
||||
%fieldset.row
|
||||
.input-group
|
||||
|
|
|
@ -13,6 +13,10 @@ module BitbucketServer
|
|||
raw['slug']
|
||||
end
|
||||
|
||||
def browse_url
|
||||
link = raw.dig('project', 'links', 'self').first.fetch('href')
|
||||
end
|
||||
|
||||
def clone_url
|
||||
raw['links']['clone'].find { |link| link['name'].starts_with?('http') }.fetch('href')
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue