odex 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/odex/app.rb +6 -1
- data/lib/odex/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6748dbaefe7b3235ebfe47fe615bb014561b9f35
|
4
|
+
data.tar.gz: ff31c7626ca8da51a575ef63fcd5623e5c1b6322
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c188136281ce91054a451c3efd529162d9055cace644584c1b70f253f4597be50c097579db520e7be9631c908c9fa293149aabfc026a6700a866341c214822b1
|
7
|
+
data.tar.gz: 352f4e64ae43dd5fe973f3b00992fe3eca99a033fa9b0ee7ff293a88b365383f0d2067812a7e5d9020ba058327c03bc27d84079e13a28742ff46360f0e523292
|
data/lib/odex/app.rb
CHANGED
@@ -152,7 +152,8 @@ module Odex
|
|
152
152
|
class Base
|
153
153
|
include Odex::Init
|
154
154
|
METHODS = [:options, :patch, :post, :put, :trace, :delete, :get, :head]
|
155
|
-
|
155
|
+
|
156
|
+
inheritable :builder, Odex::OdexBuilder.new
|
156
157
|
init_methods :c, Class.new(Req)
|
157
158
|
init_methods :route_defs, []
|
158
159
|
init_methods :hook_before, []
|
@@ -215,6 +216,10 @@ module Odex
|
|
215
216
|
hook_after << Proc.new(&block)
|
216
217
|
end
|
217
218
|
|
219
|
+
def use middleware, *args, &block
|
220
|
+
builder.use middleware, *args, &block
|
221
|
+
end
|
222
|
+
|
218
223
|
def ext(*extensions)
|
219
224
|
extensions.each do |ext|
|
220
225
|
extend ext
|
data/lib/odex/version.rb
CHANGED