diff options
author | Casey Dahlin <cdahlin@redhat.com> | 2008-10-03 17:15:53 -0400 |
---|---|---|
committer | Casey Dahlin <cdahlin@redhat.com> | 2008-10-03 17:15:53 -0400 |
commit | dc1cc9c4078603c89ec91432d12433d65fecc8eb (patch) | |
tree | cde2f1ba179b388968f92fa729735ba275b4bf89 /state.rb | |
parent | f781921d50493a886d6b214af7b77ae293ee1a7d (diff) | |
download | upstate-dc1cc9c4078603c89ec91432d12433d65fecc8eb.tar.gz upstate-dc1cc9c4078603c89ec91432d12433d65fecc8eb.tar.xz upstate-dc1cc9c4078603c89ec91432d12433d65fecc8eb.zip |
Rename respond_to to react_to
respond_to? is an API method in ruby
Diffstat (limited to 'state.rb')
-rw-r--r-- | state.rb | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -57,7 +57,7 @@ class State end # Returns true if this state should be raised if +event+ is occuring - def respond_to?(event) + def react_to?(event) return false if @active @caused_by.each do |x| return true if x === event @@ -175,7 +175,7 @@ class State raise TypeError unless event.is_a? Event count = 0 @@states.select{ |x| x.active }.each do - next unless x.respond_to? event + next unless x.react_to? event x.hold(:system) count += 1 end |