Update README.md

Swap :if / :unless examples to make more sense.
This commit is contained in:
David Hempy 2014-11-22 22:13:14 -05:00
parent c704c99381
commit 33a6e0c53c
1 changed files with 2 additions and 2 deletions

View File

@ -270,11 +270,11 @@ If you prefer a more Ruby-like guard syntax, you can use `if` and `unless` as we
```ruby
event :clean do
transitions :from => :running, :to => :cleaning, :unless => :cleaning_needed?
transitions :from => :running, :to => :cleaning, :if => :cleaning_needed?
end
event :sleep do
transitions :from => :running, :to => :sleeping, :if => :cleaning_needed?
transitions :from => :running, :to => :sleeping, :unless => :cleaning_needed?
end
end
```