sombrero 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/core/Gemfile +1 -0
- data/lib/sombrero/rtcp_controller.rb +8 -4
- data/sombrero.gemspec +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ef0fd1444aebb7291dd470b2c3e35db00513223c
|
4
|
+
data.tar.gz: af0edc1f6a1b5475e04335b694e2b2827a3918f9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 49969a561c69d8b4fce496b0c5672717212248ee88cb6412d5911499f1e7624875dcf21f85dcb488ad4701a10c523f79b55889437ceff62349b77302aad058f9
|
7
|
+
data.tar.gz: de203e8f601fd26b183e919162b3e9e64395a81f61fc81aab4e9298413d296775943ebada454afe9d3003f770af11340920a6b1fbccd271854679ec6ddfbe805
|
data/app/core/Gemfile
CHANGED
@@ -33,7 +33,11 @@ module Sombrero
|
|
33
33
|
|
34
34
|
msg = indifferent_params(JSON.parse(msg))
|
35
35
|
if controller = resolve_controller(msg[:controller])
|
36
|
-
status, _, body = call_controller(controller, msg[:method], msg[:arguments])
|
36
|
+
status, _, body = call_controller(controller, msg[:method], msg[:arguments], msg[:serial])
|
37
|
+
if body.is_a?(Proc)
|
38
|
+
body.call
|
39
|
+
return
|
40
|
+
end
|
37
41
|
if status == 200
|
38
42
|
write(serial: msg[:serial], data: body) if msg[:reply]
|
39
43
|
return
|
@@ -49,7 +53,7 @@ module Sombrero
|
|
49
53
|
end
|
50
54
|
|
51
55
|
if msg && msg[:serial]
|
52
|
-
write(serial: msg[:serial],
|
56
|
+
write(serial: msg[:serial], error: error)
|
53
57
|
else
|
54
58
|
write(error: error)
|
55
59
|
end
|
@@ -70,8 +74,8 @@ module Sombrero
|
|
70
74
|
@router.resolve_path(url)[0]
|
71
75
|
end
|
72
76
|
|
73
|
-
def call_controller controller, method, arguments
|
74
|
-
controller.initialize_controller(method, arguments).call(env.merge(rtcp_env))
|
77
|
+
def call_controller controller, method, arguments, serial
|
78
|
+
controller.initialize_controller(method, arguments).call(env.merge(rtcp_serial: serial).update(rtcp_env))
|
75
79
|
end
|
76
80
|
|
77
81
|
def write data
|
data/sombrero.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sombrero
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Slee Woo
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-03-
|
11
|
+
date: 2016-03-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rocketio
|
@@ -123,5 +123,5 @@ rubyforge_project:
|
|
123
123
|
rubygems_version: 2.5.1
|
124
124
|
signing_key:
|
125
125
|
specification_version: 4
|
126
|
-
summary: '["sombrero-0.0.
|
126
|
+
summary: '["sombrero-0.0.8", "Opinionated stack for building opinionated web applications"]'
|
127
127
|
test_files: []
|