srgs 1.1.1 → 1.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 09ae8fd3d93e778bc847e99628ed5fa18f8bc4de
4
- data.tar.gz: 10789e99188adf73abcf14d6043fe5435838db79
3
+ metadata.gz: 9f8d7b7261150f779271b46747725695f7f7db6f
4
+ data.tar.gz: d6127b54a7182f7d272cb5fc2887cefc10477ed9
5
5
  SHA512:
6
- metadata.gz: a0cac0904476a5ff583ffb258b26e9fa185e26d6acc544fbd3ac68be996f90feb972fcbcc7224fcd7d745c6731b114ea0626751d8c48cc64908cf47f51c50e66
7
- data.tar.gz: 748ced379529b9838cfb94c8f7946408aaff79f6334f505923fc91a875176df026758a1e1eda2916d1270dedae05b95d707fc0af56a69b8f769bbbca39ed0a60
6
+ metadata.gz: c4911df2a96527af8fe7b632e53723d9aaed1cc4232772d1189b7087ac0cd4e459a5932a3e1c059a3df6c6acfa9fb550d48d9c0c6287c9e227df5fdc41728c81
7
+ data.tar.gz: ec8ca2c254e19811e88d8980a3387cc1cb54d690f2aeea16f5f802101d05b1ee130bfe14740e6cf3e66b06650a3fa039a7eb4b3f5e6fb4961082c4baaf5c08ce
@@ -4,7 +4,8 @@ module Srgs
4
4
  attr_accessor :elements, :repeat, :repeat_prob, :weight
5
5
 
6
6
  def initialize(element = '', repeat=nil, repeat_prob = nil, weight = nil)
7
- @elements = [element]
7
+ @elements = []
8
+ @elements << element unless element == ''
8
9
  @repeat = repeat
9
10
  @repeat_prob = repeat_prob
10
11
  @weight = weight
@@ -43,6 +43,8 @@ module Srgs
43
43
  text(element, xml)
44
44
  when OneOf
45
45
  one_of(element, xml)
46
+ when Item
47
+ item(element, xml)
46
48
  else
47
49
  raise "Can't add #{element.class} to item."
48
50
  end
@@ -1,3 +1,3 @@
1
1
  module Srgs
2
- VERSION = "1.1.1"
2
+ VERSION = "1.1.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: srgs
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - kristenmills
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-01-30 00:00:00.000000000 Z
11
+ date: 2014-02-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler