From 1b752968757873434404a2bf82ea360ce829ec87 Mon Sep 17 00:00:00 2001 From: Tim Zallmann Date: Mon, 2 Oct 2017 15:44:58 +0200 Subject: Fixed Linting errors + tests --- app/helpers/lazy_image_tag_helper.rb | 2 +- app/models/concerns/avatarable.rb | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) (limited to 'app') diff --git a/app/helpers/lazy_image_tag_helper.rb b/app/helpers/lazy_image_tag_helper.rb index aea1fcc7e91..60df16b3373 100644 --- a/app/helpers/lazy_image_tag_helper.rb +++ b/app/helpers/lazy_image_tag_helper.rb @@ -9,7 +9,7 @@ module LazyImageTagHelper unless options.delete(:lazy) == false options[:data] ||= {} - unless options.delete(:use_original_source) == true + unless options.delete(:use_original_source) options[:data][:src] = path_to_image(source) else options[:data][:src] = source diff --git a/app/models/concerns/avatarable.rb b/app/models/concerns/avatarable.rb index ddaa15e6a0d..6ed57dea858 100644 --- a/app/models/concerns/avatarable.rb +++ b/app/models/concerns/avatarable.rb @@ -13,10 +13,8 @@ module Avatarable # If asset_host is set then it is expected that assets are handled by a standalone host. # That means we do not want to get GitLab's relative_url_root option anymore. host = asset_host.present? ? asset_host : gitlab_host - - [host, avatar.url].join - else - [host, avatar.url].join end + + [host, avatar.url].join end end -- cgit v1.2.1