<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,3 +1,20 @@
 class Comment &lt; Sofa::Record  
   validates_present :body
+
+  def self.find_all
+    self.temp_view &lt;&lt;-JS
+      if (doc.document_type == 'Comment') {
+        emit(doc.created_at, doc)
+      }
+    JS
+  end
+
+  def self.find_all_unapproved
+    self.temp_view &lt;&lt;-JS
+      if (doc.document_type == 'Comment' &amp;&amp; doc.approved != true) {
+        emit(doc.created_at, doc)
+      }
+    JS
+  end
+
 end</diff>
      <filename>app/models/comment.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>599589a9cb9b8db8486f26fa5c0ae6ac918d1845</id>
    </parent>
  </parents>
  <author>
    <name>Nic Benders</name>
    <email>nic.benders@gmail.com</email>
  </author>
  <url>http://github.com/gnarg/blarg/commit/3b4c0af47dca67c5b93fbf3780b3a01b618831bb</url>
  <id>3b4c0af47dca67c5b93fbf3780b3a01b618831bb</id>
  <committed-date>2009-07-29T18:19:31-07:00</committed-date>
  <authored-date>2009-07-29T18:19:31-07:00</authored-date>
  <message>Add find_all and find_all_unapproved to the Comment model</message>
  <tree>40dd2f0249ff0608fd612c9e9a19a3febdb8879e</tree>
  <committer>
    <name>Nic Benders</name>
    <email>nic.benders@gmail.com</email>
  </committer>
</commit>
