rackif 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (5) hide show
  1. data/README.rdoc +1 -1
  2. data/VERSION +1 -1
  3. data/lib/if.rb +1 -1
  4. data/lib/rackif.rb +17 -0
  5. metadata +2 -2
@@ -1,6 +1,6 @@
1
1
  = Rack::If
2
2
 
3
- Use or don't use rack apps based on a variety of environment variables. That was the original purpose of this gem, however Rack::If basically allows you make adjustment to the Rack stack based on environment variables.
3
+ Use or don't use rack apps based on a variety of environment variables.
4
4
 
5
5
  == Use
6
6
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.0
1
+ 0.1.1
data/lib/if.rb CHANGED
@@ -1,4 +1,4 @@
1
- class Rack::If
1
+ class Rack::IfProcessing
2
2
 
3
3
  attr_reader :app, :env
4
4
 
@@ -1 +1,18 @@
1
1
  require File.dirname(__FILE__) + '/if'
2
+
3
+ class Rack::If
4
+
5
+ attr_reader :app
6
+
7
+ def initialize(app, options={}, &block)
8
+ @options = options
9
+ @app = app
10
+
11
+ @block = block
12
+ end
13
+
14
+ def call(rack_environment)
15
+ Rack::IfProcessing.new(app,@options, &@block).call(rack_environment)
16
+ end
17
+
18
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rackif
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sam Schenkman-Moore
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2009-12-09 00:00:00 -05:00
13
+ date: 2009-12-15 00:00:00 -05:00
14
14
  default_executable:
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency