<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,4 +1,4 @@
-Copyright (c) 2008 [name of plugin creator]
+Copyright (c) 2008 Jared Carroll and Dan Croak
 
 Permission is hereby granted, free of charge, to any person obtaining
 a copy of this software and associated documentation files (the</diff>
      <filename>MIT-LICENSE</filename>
    </modified>
    <modified>
      <diff>@@ -3,9 +3,9 @@ When
 
 When adds :if and :unless conditions to ActiveRecord callbacks 
 and validations and ActionController filters. It works exactly 
-the way as the current implementation of validates_acceptance_of.
+the way as the current implementation of #validates_acceptance_of.
 
-It works on all 14 callbacks:
+It works on the following callbacks:
 
 before_validation
 before_validation_on_create
@@ -19,8 +19,6 @@ after_update
 after_save
 before_destroy
 after_destroy
-after_initialize
-after_find
 
 3 validations:
 
@@ -28,24 +26,22 @@ validate
 validate_on_create
 validate_on_update
 
-and 3 filters:
+and 1 filter:
 
 before_filter
-after_filter
-around_filter
 
-It works when :if or :unless is passed symbols, lambdas, and strings.
+It works when :if or :unless is passed a Symbol, a lambdas or a String.
 They should return or evaluate to a true or false value.
 
-
 Example
 =======
 
 class Address &lt; ActiveRecord::Base
+
   before_save :geolocate
 
   def geolocate
-    if self.complete?
+    if complete?
       ...
     end
   end
@@ -53,6 +49,7 @@ class Address &lt; ActiveRecord::Base
   def complete?
     street? &amp;&amp; city? &amp;&amp; state? &amp;&amp; zip?
   end
+
 end
 
 In this case, we want to find the latitude and longitude of an address only if 
@@ -66,7 +63,9 @@ With When, the WHEN responsibility is moved to where it belongs:
 as part of the callback.
 
 class Address &lt; ActiveRecord::Base
-  before_save :geolocate, :if =&gt; :complete?
+
+  before_save :geolocate, 
+    :if =&gt; :complete?
 
   def geolocate
     ...
@@ -75,32 +74,20 @@ class Address &lt; ActiveRecord::Base
   def complete?
     street? &amp;&amp; city? &amp;&amp; state? &amp;&amp; zip?
   end
+
 end
 
 The callback's single responsibility is to execute code WHEN certain conditions are met.
-The geolocate method's single responsibility is to ... geolocate.
-
+The #geolocate method's single responsibility is to ... geolocate.
 
 More Examples
 =============
 
-after_update :send_notifications, :unless =&gt; lambda {|record| record.minor_change?}
-
-after_initialize :capitalize_title, :if =&gt; :new_record?
-
-before_create %{self.password = password.to_sha1},
+before_create :encrypt_password,
   :unless =&gt; lambda {|user| user.password_confirmation.blank?}
 
-before_create :unless =&gt; lambda {|user| user.password_confirmation.blank?} do |record|
-  record.password = record.password.to_sha1
-end
-
-before_create PasswordEncryptor, :unless =&gt; lambda {|user| user.password_confirmation.blank?}
-class PasswordEncryptor
-  def self.before_create(record)
-    record.password = record.password.to_sha1
-  end
-end
-
+before_filter :log_in!,
+  :only =&gt; [:new, :create],
+  :unless =&gt; :logged_in?
 
 Copyright (c) 2008 Jared Carroll and Dan Croak, released under the MIT license</diff>
      <filename>README</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>ac8f84c4bed35bdf6b4bc383d4f94f5842c5393c</id>
    </parent>
  </parents>
  <author>
    <name>jcarroll</name>
    <email>jcarroll@7bbfaf0e-4d1d-0410-9690-a8bb5f8ef2aa</email>
  </author>
  <url>http://github.com/thoughtbot/when/commit/b35c5eebfc4732d984101dd411b2545f15026063</url>
  <id>b35c5eebfc4732d984101dd411b2545f15026063</id>
  <committed-date>2008-02-13T16:25:45-08:00</committed-date>
  <authored-date>2008-02-13T16:25:45-08:00</authored-date>
  <message>updated the README

git-svn-id: https://svn.thoughtbot.com/plugins/when/trunk@330 7bbfaf0e-4d1d-0410-9690-a8bb5f8ef2aa</message>
  <tree>9ab01e1208b86ad5b643707d9d559aa605bf267d</tree>
  <committer>
    <name>jcarroll</name>
    <email>jcarroll@7bbfaf0e-4d1d-0410-9690-a8bb5f8ef2aa</email>
  </committer>
</commit>
