summaryrefslogtreecommitdiffstats
path: root/state.rb
diff options
context:
space:
mode:
authorCasey Dahlin <cdahlin@redhat.com>2008-10-03 17:55:44 -0400
committerCasey Dahlin <cdahlin@redhat.com>2008-10-03 17:55:44 -0400
commit1e69719c7b424e26a5430488eb06099269e14164 (patch)
treee012b4040543ec4d5c977a079374ff0bd343713e /state.rb
parent81ddc500c0954f92e5adf44906c9a1f4313bf25b (diff)
downloadupstate-1e69719c7b424e26a5430488eb06099269e14164.tar.gz
upstate-1e69719c7b424e26a5430488eb06099269e14164.tar.xz
upstate-1e69719c7b424e26a5430488eb06099269e14164.zip
Fix type check in StatePattern#initialize
The check for inheritance was in the wrong direction
Diffstat (limited to 'state.rb')
-rw-r--r--state.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/state.rb b/state.rb
index f9bfecb..a05cc05 100644
--- a/state.rb
+++ b/state.rb
@@ -301,7 +301,7 @@ class StatePattern
# parameters. The parameters in the hash can be string values to match or
# Regex objects
def initialize(stateclass, params = {})
- raise TypeError unless State < stateclass
+ raise TypeError unless State > stateclass
raise TypeError unless params.is_a? Hash
@stateclass = stateclass
@params = params