diff options
| author | Z.J. van de Weg <git@zjvandeweg.nl> | 2017-02-07 15:16:46 +0100 |
|---|---|---|
| committer | Z.J. van de Weg <git@zjvandeweg.nl> | 2017-02-07 15:16:46 +0100 |
| commit | 128b1eae092e4ee9384c99a4ba72b9122fc17e89 (patch) | |
| tree | 8eab2084903f6455c40e969cbc3d8ef02582288e /lib/api/entities.rb | |
| parent | 68db614d17c3ad984f7a5698d02475f71bde8941 (diff) | |
| download | gitlab-ce-128b1eae092e4ee9384c99a4ba72b9122fc17e89.tar.gz | |
Update Rubocop to ruby 2.3zj-drop-ruby-21-tests
Diffstat (limited to 'lib/api/entities.rb')
| -rw-r--r-- | lib/api/entities.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/api/entities.rb b/lib/api/entities.rb index b1ead48caf7..bedcd503724 100644 --- a/lib/api/entities.rb +++ b/lib/api/entities.rb @@ -382,9 +382,7 @@ module API expose :author, using: Entities::UserBasic, if: ->(event, options) { event.author } expose :author_username do |event, options| - if event.author - event.author.username - end + event.author&.username end end |
