<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,4 +1,8 @@
-== 2.3.2 relased 2009-08-26
+== 2.3.3 released 2009-09-02
+
+* Split out merging scopes with 'or' into a convenient method.
+
+== 2.3.2 released 2009-08-26
 
 * Add in scope_procedure as an alias for alias_scope.
 * Fixed bug with not_blank condition.</diff>
      <filename>CHANGELOG.rdoc</filename>
    </modified>
    <modified>
      <diff>@@ -96,11 +96,21 @@ module Searchlogic
         
         def create_or_condition(scopes, args)
           named_scope scopes.join(&quot;_or_&quot;), lambda { |*args|
-            scopes_options = scopes.collect { |scope| send(scope, *args).proxy_options }
-            conditions = scopes_options.reject { |o| o[:conditions].nil? }.collect { |o| sanitize_sql(o[:conditions]) }
-            scopes.inject(scoped({})) { |scope, scope_name| scope.send(scope_name, *args) }.scope(:find).merge(:conditions =&gt; &quot;(&quot; + conditions.join(&quot;) OR (&quot;) + &quot;)&quot;)
+            merge_scopes_with_or(scopes.collect { |scope| [scope, *args] })
           }
         end
+        
+        def merge_scopes_with_or(scopes)
+          scopes_options = scopes.collect { |scope, *args| send(scope, *args).proxy_options }
+          conditions = scopes_options.reject { |o| o[:conditions].nil? }.collect { |o| sanitize_sql(o[:conditions]) }
+          
+          scope = scopes.inject(scoped({})) do |scope, info|
+            scope_name, *args = info
+            scope.send(scope_name, *args)
+          end
+          
+          scope.scope(:find).merge(:conditions =&gt; &quot;(&quot; + conditions.join(&quot;) OR (&quot;) + &quot;)&quot;)
+        end
     end
   end
 end
\ No newline at end of file</diff>
      <filename>lib/searchlogic/named_scopes/or_conditions.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>cdd01db6789ae686b58ad2c5f373cf0da36b6b25</id>
    </parent>
  </parents>
  <author>
    <name>binarylogic</name>
    <email>bjohnson@binarylogic.com</email>
  </author>
  <url>http://github.com/binarylogic/searchlogic/commit/357874cc713042f850e34cecd89ecfdaaa375208</url>
  <id>357874cc713042f850e34cecd89ecfdaaa375208</id>
  <committed-date>2009-09-02T15:49:51-07:00</committed-date>
  <authored-date>2009-09-02T15:49:51-07:00</authored-date>
  <message>* Split out merging scopes with or into a convenient method.</message>
  <tree>84fea5f896921481a2bfd412dbb09df61bb0a00d</tree>
  <committer>
    <name>binarylogic</name>
    <email>bjohnson@binarylogic.com</email>
  </committer>
</commit>
