sinatra-cometio 0.5.1 → 0.5.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: 46011b78d7f07c4031536b64d3670ccdc9b10063
4
- data.tar.gz: 27dfbb11e619502f2fa05be52377896f7dc91e60
3
+ metadata.gz: 4340d27e7e828310edf2e977f5c6a631cf14e1c4
4
+ data.tar.gz: 3c31cd77caa527eebba3b6ac625893e3840264bb
5
5
  SHA512:
6
- metadata.gz: 7965c0eeb836897d74acbcfa4d376123c711046f37d506f00854471e393c033ac08ee881ee243e06cb309a81e3b152ce639f6fc7b33cfa097bdc88d56562e8c2
7
- data.tar.gz: d88674a1b9957607e6fe8aa2f99c71f3786a7de5f8c4e69d4714ddc7b5f2b5cd049901a5848de265a37853bbc8af3459a334fb1579776c7b302e08db9000ef48
6
+ metadata.gz: 522551d054a61d3abab658025adfcba67be3a6a8912cacab6d4e41a2b3441140d1478af1422efe602f59e3a9f28d140213fb74ca105f9aac427994f38ebc57d6
7
+ data.tar.gz: 94e529d321863dde674bd8520e4e9720267c32c0543dcb8fc68165335e866b4fa798fe0a85db8f43392b5ade4b975e9da796c3331c6c772bcf844c23afe5a313
data/History.txt CHANGED
@@ -1,3 +1,7 @@
1
+ === 0.5.2 2013-04-03
2
+
3
+ * print invalid setting error
4
+
1
5
  === 0.5.1 2013-04-03
2
6
 
3
7
  * config post interval - "set :cometio, :post_interval => 1"
@@ -30,10 +30,16 @@ module Sinatra
30
30
  @@options = {}
31
31
  opts.each do |k,v|
32
32
  k = k.to_sym
33
- if default_options.include? k
34
- @@options[k] = default_options[k][1].call(v) ? v : default_options[k][0]
33
+ unless default_options.include? k
34
+ STDERR.puts "!! #{self} setting - \"#{k}\" is not valid key"
35
35
  else
36
- @@options[k] = v
36
+ unless default_options[k][1].call(v)
37
+ default = default_options[k][0]
38
+ STDERR.puts "!! #{self} setting - \"#{k} => #{v}\" is not valid. set default \"#{k} => #{default}\""
39
+ @@options[k] = default
40
+ else
41
+ @@options[k] = v
42
+ end
37
43
  end
38
44
  end
39
45
  default_options.each do |k, v|
@@ -1,5 +1,5 @@
1
1
  module Sinatra
2
2
  module CometIO
3
- VERSION = '0.5.1'
3
+ VERSION = '0.5.2'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sinatra-cometio
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sho Hashimoto
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-04-02 00:00:00.000000000 Z
11
+ date: 2013-04-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler