Refactor all .length === 0
patterns in JS (#30045)
This pattern comes of often during review, so let's fix it once and for all. Did not test, but changes are trivial enough imho.
This commit is contained in:
@ -453,7 +453,7 @@ export function initRepositoryActionView() {
|
||||
{{ locale.showFullScreen }}
|
||||
</a>
|
||||
<div class="divider"/>
|
||||
<a :class="['item', currentJob.steps.length === 0 ? 'disabled' : '']" :href="run.link+'/jobs/'+jobIndex+'/logs'" target="_blank">
|
||||
<a :class="['item', !currentJob.steps.length ? 'disabled' : '']" :href="run.link+'/jobs/'+jobIndex+'/logs'" target="_blank">
|
||||
<i class="icon"><SvgIcon name="octicon-download"/></i>
|
||||
{{ locale.downloadLogs }}
|
||||
</a>
|
||||
|
Reference in New Issue
Block a user