From c177784d5af6b47ae613f922e075a38fc56ad711 Mon Sep 17 00:00:00 2001 From: Grzegorz Bizon Date: Tue, 29 Dec 2015 11:40:57 +0100 Subject: Use short method call in StringPath instead block --- lib/gitlab/string_path.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/gitlab/string_path.rb b/lib/gitlab/string_path.rb index 1eb8162f805..af80a502bf6 100644 --- a/lib/gitlab/string_path.rb +++ b/lib/gitlab/string_path.rb @@ -72,7 +72,7 @@ module Gitlab def directories return [] unless directory? - children.select { |child| child.directory? } + children.select(&:directory?) end def directories! @@ -81,7 +81,7 @@ module Gitlab def files return [] unless directory? - children.select { |child| child.file? } + children.select(&:file?) end def ==(other) -- cgit v1.2.1