rack-read_only 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/rack/read_only.rb +4 -0
- data/lib/rack/read_only/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: f397f956998a6f99dd9b91047d00222b41a78ab0
|
4
|
+
data.tar.gz: 4fa72e7e2d8cf889acd787fa347c5c6981f921dc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2d75c8f318ab40ea42859f1d3c7271a0bb590c19d8183810295356b24b5b23dac0910109a6abbc6fc04c90342d302f325b43c92e35c9f41d0d76b48e99c070c6
|
7
|
+
data.tar.gz: ad690ac13fe841edfbdddaeb7c1e307c230557f0d2ee6388fe18eaef636b11827aefab9d577640b28cf8c92c1067b5af981498f01cec131641a8193f6f2887ab
|
data/lib/rack/read_only.rb
CHANGED
@@ -2,6 +2,10 @@ require "rack/read_only/version"
|
|
2
2
|
|
3
3
|
module Rack
|
4
4
|
class ReadOnly
|
5
|
+
READ_METHODS = %w(HEAD GET OPTIONS)
|
6
|
+
WRITE_METHODS = %w(POST PUT DELETE PATCH)
|
7
|
+
ALL_METHODS = READ_METHODS + WRITE_METHODS
|
8
|
+
|
5
9
|
attr_reader :app, :options
|
6
10
|
|
7
11
|
def initialize(app, options = {})
|