watts 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/Rakefile +1 -1
  2. data/lib/watts.rb +9 -1
  3. metadata +4 -4
data/Rakefile CHANGED
@@ -22,7 +22,7 @@ spec = Gem::Specification.new { |s|
22
22
  "Resource-oriented, Rack-based, minimalist web framework."
23
23
  s.homepage = "http://debu.gs/#{s.name}"
24
24
  %w(metaid).each &s.method(:add_dependency)
25
- s.version = '1.0.0'
25
+ s.version = '1.0.1'
26
26
  }
27
27
 
28
28
  Rake::RDocTask.new(:doc) { |t|
@@ -43,7 +43,7 @@ module Watts
43
43
  accnext = acc.dup << args[0]
44
44
 
45
45
  each { |k,sub|
46
- t = sub.rmatch res, args, [k] + acc
46
+ t = sub.rmatch res, args, acc + [k]
47
47
  return t if t
48
48
 
49
49
  if k.kind_of?(Regexp) && k.match(args[0])
@@ -307,6 +307,14 @@ module Watts
307
307
  },
308
308
  ['Method not allowed.']]
309
309
  end
310
+
311
+ # HEAD responds the same way as the default_method, but does not return
312
+ # a body.
313
+ def head(*args)
314
+ r = default_http_method
315
+ r[2] = []
316
+ r
317
+ end
310
318
  end
311
319
 
312
320
  # See the documentation for Watts::Resource.for_html_view().
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: watts
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-06-24 00:00:00.000000000 Z
12
+ date: 2012-08-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: metaid
16
- requirement: &15368000 !ruby/object:Gem::Requirement
16
+ requirement: &8293680 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,7 +21,7 @@ dependencies:
21
21
  version: '0'
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *15368000
24
+ version_requirements: *8293680
25
25
  description:
26
26
  email: pete@debu.gs
27
27
  executables: []