bstard 0.2.2 → 0.2.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- MTc5MTIxYjYyOGVkYWM2OTA0NzA0NzU3NWE5YTMyMGJiYjM2MmFkMA==
4
+ MjRmN2FjOTNjZjJkOWI0NDcxMzU3MTNjZDkxMmM0MGQyMTliZTc1ZQ==
5
5
  data.tar.gz: !binary |-
6
- ZjEwNWEwZjZkMTNjMGIzNzhiMTVmN2RlYzQyMjQ0YmI1YWNjZjkxYw==
6
+ NTNhZjk0MDJjNDk2YjE5ZGNjZmE3MTdmMGVkZmU0Zjg3NDk2NTE0Zg==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- NDg0NzdiMTUxZTA5YjVlYjUwYzU2ZjkzNjg5ZWQ1ZDMyMjNlY2ZkMzBiYmIy
10
- Mzk5NTkwOTgwYmEzZDhlMTA2NjBkMDkzODNmYThjMDE2YjJiZjE2YTM0YmMx
11
- MGFhYTY1M2RlYWFjMDlmYzc1Mjg5MTkzZjljYTJhODI1YjA3ZjA=
9
+ NDY4MzExMjVhMTBiYjM4Nzc5MzY2YzUxODMwY2E0NTcxMTA4NjJkNDg5YWU3
10
+ MTdjNmY5NTMzYzg4NmU4MDUyYWVmZmM0ZWNjZTVlYWUyNTgxMDlmMzEwM2Zj
11
+ NGY3YjdjYmUzZjIyMjVkZGFjNTJlZjRjNmY0MDljZDlkMWIxZDM=
12
12
  data.tar.gz: !binary |-
13
- M2M1YTJhNDMzYjU4NjM0OWViZmQyMjhiNWVlYjE4NmIzMmFkNGFiZjhhNDBk
14
- NDNjZDk5YzE1MzU0MDhiYTRlY2UzNmVlYWI1MjVkYWJiYzM4N2M4NWU3MjIy
15
- MzI5Y2UwMGU4YTljMmE0NWJlNTY1ZjVmMTE5ZGY0ZTViNjgyZjk=
13
+ MGYyZjIzYWE3ODA0MDdiYmI4NzRhOTFhNmNiMTRkZDVkMmEwNzU3OGY3YmQx
14
+ Y2U5OTdlOTQ1Y2YzNmU1YmM5ZWNjNTRlNjM4ODhhOTk1YTRmNjExMWFiNWEx
15
+ ZDdjZDVhOGQ3OGQyZjljOTIwNTgzZGZhODJkNDg5ODUwM2Y0OWE=
data/lib/bstard/fsm.rb CHANGED
@@ -11,8 +11,8 @@ class Bstard::Fsm
11
11
 
12
12
  def initial(state)
13
13
  unless state.nil?
14
- @current_state = state
15
- add_state(state)
14
+ @current_state = state.to_sym
15
+ add_state(current_state)
16
16
  end
17
17
  end
18
18
 
@@ -20,7 +20,7 @@ class Bstard::Fsm
20
20
  evt = event_name.to_sym
21
21
  t = @events.fetch(evt, {})
22
22
  @events[evt] = t.merge(transitions)
23
- transitions.each { |k,v| add_state(k); add_state(v) }
23
+ transitions.each { |k,v| add_state(k.to_sym); add_state(v.to_sym) }
24
24
  add_event_method(evt)
25
25
  add_can_event_method(evt)
26
26
  end
@@ -1,4 +1,4 @@
1
1
  module Bstard
2
- VERSION = '0.2.2'
2
+ VERSION = '0.2.3'
3
3
  end
4
4
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bstard
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tony Headford