Don't show "changed files" if event can't have them (#1191)

Closes #1190
This commit is contained in:
qwerty287 2022-09-16 17:04:44 +02:00 committed by GitHub
parent ac2f1d26e8
commit 00a475f605
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -36,7 +36,11 @@
<Tabs v-model="activeTab" disable-hash-mode class="order-2 md:order-none">
<Tab id="tasks" :title="$t('repo.build.tasks')" />
<Tab id="config" :title="$t('repo.build.config')" />
<Tab id="changed-files" :title="$t('repo.build.files', { files: build.changed_files?.length || 0 })" />
<Tab
v-if="build.event === 'push' || build.event === 'pull_request'"
id="changed-files"
:title="$t('repo.build.files', { files: build.changed_files?.length || 0 })"
/>
</Tabs>
<div class="flex justify-between gap-x-4 text-color flex-shrink-0 pb-2 md:p-0 mx-auto md:mr-0">