1
0
Fork 0
mirror of https://github.com/aasm/aasm synced 2023-03-27 23:22:41 -04:00

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

View file

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