<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -8,7 +8,6 @@ Similar to find_by_attribute methods, these macros provide a more flexible scopi
 
   User.for_group_id(10).find(:all)
 
-Also provides `by` scope that allows you to add order constraints to a query cleanly.
-
-  User.by(:created_at, :desc)
+Also provides `order_by` scope that allows you to add order constraints to a query cleanly.
 
+  User.order_by('created_at DESC', 'id')</diff>
      <filename>README</filename>
    </modified>
    <modified>
      <diff>@@ -5,9 +5,9 @@ class ActiveRecord::Base
       lambda { |attribute_value| { :conditions =&gt; { attribute =&gt; attribute_value } } }
   end
 
-  named_scope :by, Proc.new { |attribute, desc|
-    raise ArgumentError, 'An attribute to order by must be specified' unless attribute
-    { :order =&gt; &quot;#{attribute}#{ desc &amp;&amp; :asc != desc ? ' DESC' : '' }&quot; }
+  named_scope :order_by, Proc.new { |*attributes|
+    raise ArgumentError, 'You must specify an attribute to order by' if attributes.blank?
+    { :order =&gt; attributes.join(', ') }
   }
 
 end</diff>
      <filename>init.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>b0333a3c458506b14b9935e858000c0822f6118d</id>
    </parent>
  </parents>
  <author>
    <name>Duncan Beevers</name>
    <email>duncanbeevers@gmail.com</email>
  </author>
  <url>http://github.com/duncanbeevers/named_scope_for/commit/85e525e198cd138b3d15854d94e143ad7e3f3a2b</url>
  <id>85e525e198cd138b3d15854d94e143ad7e3f3a2b</id>
  <committed-date>2008-05-09T01:54:52-07:00</committed-date>
  <authored-date>2008-05-09T01:54:52-07:00</authored-date>
  <message>Change `by` to `order_by`.  Simplify usage, allow for multiple supplied orderings.</message>
  <tree>25ab2bfe8249850d8847733bd697aa18b6add4c0</tree>
  <committer>
    <name>Duncan Beevers</name>
    <email>duncanbeevers@gmail.com</email>
  </committer>
</commit>
