Skip to content
This repository was archived by the owner on Apr 12, 2020. It is now read-only.

Commit 281b636

Browse files
committed
Display tags and branches only if exist
1 parent 370407a commit 281b636

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

src/Gitonomy/Browser/Resources/views/repository.html.twig

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
{% extends "layout.html.twig" %}
22

33
{% block content %}
4-
<h3>Branches</h3>
5-
{{ git_branches(repository) }}
4+
{% if repository.references.branches %}
5+
<h3>Branches</h3>
6+
{{ git_branches(repository) }}
7+
{% endif %}
68

7-
<h3>Tags</h3>
8-
{{ git_tags(repository) }}
9+
{% if repository.references.tags %}
10+
<h3>Tags</h3>
11+
{{ git_tags(repository) }}
12+
{% endif %}
913

1014
<h3>Logs</h3>
1115
{{ git_log(repository.log.setLimit(30), {query_url: path('log_ajax')}) }}

0 commit comments

Comments
 (0)