From d30330441ab5b086b85a1c546125fc0218265b63 Mon Sep 17 00:00:00 2001 From: Josh Susser and Avdi Grimm Date: Fri, 17 May 2013 14:06:58 -0400 Subject: [PATCH] Refactored conditional to an || to be more idiomatic. --- app/models/group.rb | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/app/models/group.rb b/app/models/group.rb index c96248ebd29..e16af207bf0 100644 --- a/app/models/group.rb +++ b/app/models/group.rb @@ -77,10 +77,7 @@ class Group < ActiveRecord::Base end def self.[](name) - unless g = lookup_group(name) - g = refresh_automatic_group!(name) - end - g + lookup_group(name) || refresh_automatic_group!(name) end def self.lookup_group(name)