diff options
author | Simon Knox <psimyn@gmail.com> | 2018-01-04 21:57:28 +1100 |
---|---|---|
committer | Simon Knox <psimyn@gmail.com> | 2018-01-04 21:57:28 +1100 |
commit | e35c4c401f09340ebee2b0c92aec1560c54c1692 (patch) | |
tree | 1bbb803376c133efe8bd6e3425d990c797ffebed | |
parent | baf3dc0ce5b551a7cdc7969cf0cfc35d50188988 (diff) | |
download | gitlab-ce-e35c4c401f09340ebee2b0c92aec1560c54c1692.tar.gz |
prefer ternary
-rw-r--r-- | app/assets/javascripts/notes/components/noteable_discussion.vue | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/app/assets/javascripts/notes/components/noteable_discussion.vue b/app/assets/javascripts/notes/components/noteable_discussion.vue index 99ddb8cdf78..76c1aecc336 100644 --- a/app/assets/javascripts/notes/components/noteable_discussion.vue +++ b/app/assets/javascripts/notes/components/noteable_discussion.vue @@ -92,16 +92,10 @@ return this.unresolvedDiscussions.length > 0; }, wrapperComponent() { - if (this.discussion.diffDiscussion && this.discussion.diffFile) { - return diffWithNote; - } - return 'div'; + return (this.discussion.diffDiscussion && this.discussion.diffFile) ? diffWithNote : 'div'; }, wrapperClass() { - if (this.isDiffDiscussion) { - return ''; - } - return 'panel panel-default'; + return this.isDiffDiscussion ? '' : 'panel panel-default'; }, }, methods: { |