From 0f95d74827cc4f0bc6a8ef234873a6f72613a5f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dennis=20G=C3=BCnnewig?= Date: Thu, 8 Jan 2015 14:58:00 +0100 Subject: [PATCH] Use guard clause --- .../lib/middleman-core/sitemap/extensions/proxies.rb | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/middleman-core/lib/middleman-core/sitemap/extensions/proxies.rb b/middleman-core/lib/middleman-core/sitemap/extensions/proxies.rb index ae8f4580..8fb29cc8 100644 --- a/middleman-core/lib/middleman-core/sitemap/extensions/proxies.rb +++ b/middleman-core/lib/middleman-core/sitemap/extensions/proxies.rb @@ -67,11 +67,9 @@ module Middleman mime_type = super return mime_type if mime_type - if proxy? - proxied_to_resource.content_type - else - nil - end + return proxied_to_resource.content_type if proxy? + + nil end end