faraday_middleware 0.2.2 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/.gitignore CHANGED
@@ -1,24 +1,24 @@
1
- ## MAC OS
2
- .DS_Store
3
-
4
- ## TEXTMATE
5
- *.tmproj
6
- tmtags
7
-
8
- ## EMACS
9
- *~
10
- \#*
11
- .\#*
12
-
13
- ## VIM
14
- *.swp
15
-
16
- ## PROJECT::GENERAL
17
- coverage
18
- rdoc
19
- pkg
20
- *.gem
21
- .yardopts
22
- .yardoc
23
-
24
- ## PROJECT::SPECIFIC
1
+ ## MAC OS
2
+ .DS_Store
3
+
4
+ ## TEXTMATE
5
+ *.tmproj
6
+ tmtags
7
+
8
+ ## EMACS
9
+ *~
10
+ \#*
11
+ .\#*
12
+
13
+ ## VIM
14
+ *.swp
15
+
16
+ ## PROJECT::GENERAL
17
+ coverage
18
+ rdoc
19
+ pkg
20
+ *.gem
21
+ .yardopts
22
+ .yardoc
23
+
24
+ ## PROJECT::SPECIFIC
@@ -1,10 +1,10 @@
1
- # Changelog
2
-
3
- ### 0.0.2 September 25, 2010
4
-
5
- * Mashify now handles arrays of non-hashes
6
-
7
- ### 0.0.1 June 27, 2010
8
-
9
- * MultiJSON
1
+ # Changelog
2
+
3
+ ### 0.0.2 September 25, 2010
4
+
5
+ * Mashify now handles arrays of non-hashes
6
+
7
+ ### 0.0.1 June 27, 2010
8
+
9
+ * MultiJSON
10
10
  * Mashify
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- faraday_middleware (0.2.2)
4
+ faraday_middleware (0.2.3)
5
5
  faraday (~> 0.5.2)
6
6
 
7
7
  GEM
@@ -14,7 +14,7 @@ GEM
14
14
  rack (>= 1.1.0, < 2)
15
15
  hashie (0.4.0)
16
16
  json (1.4.6)
17
- multi_json (0.0.4)
17
+ multi_json (0.0.5)
18
18
  multi_xml (0.2.0)
19
19
  multipart-post (1.0.1)
20
20
  oauth2 (0.1.0)
data/README.md CHANGED
@@ -14,7 +14,7 @@ Let's decode the response body with [MultiJson](http://github.com/intridea/multi
14
14
 
15
15
  conn = Faraday::Connection.new(:url => 'http://api.twitter.com/1') do |builder|
16
16
  builder.adapter Faraday.default_adapter
17
- builder.use Faraday::Response::MultiJson
17
+ builder.use Faraday::Response::Parse
18
18
  end
19
19
 
20
20
  resp = conn.get do |req|
@@ -30,7 +30,7 @@ Want to ditch the brackets and use dot notation? [Mashify](http://github.com/int
30
30
 
31
31
  conn = Faraday::Connection.new(:url => 'http://api.twitter.com/1') do |builder|
32
32
  builder.adapter Faraday.default_adapter
33
- builder.use Faraday::Response::MultiJson
33
+ builder.use Faraday::Response::Parse
34
34
  builder.use Faraday::Response::Mashify
35
35
  end
36
36
 
@@ -40,4 +40,4 @@ Want to ditch the brackets and use dot notation? [Mashify](http://github.com/int
40
40
 
41
41
  u = resp.body
42
42
  u.name
43
- # => "Wynn Netherland"
43
+ # => "Wynn Netherland"
data/Rakefile CHANGED
@@ -1,14 +1,14 @@
1
- $LOAD_PATH.unshift File.expand_path("../lib", __FILE__)
2
- require 'rake'
3
- require 'rake/testtask'
4
- require 'bundler'
5
-
6
- Bundler::GemHelper.install_tasks
7
-
8
- Rake::TestTask.new(:test) do |test|
9
- test.ruby_opts = ["-rubygems"] if defined? Gem
10
- test.libs << "lib" << "test"
11
- test.pattern = "test/**/*_test.rb"
12
- end
13
-
14
- task :default => :test
1
+ $LOAD_PATH.unshift File.expand_path("../lib", __FILE__)
2
+ require 'rake'
3
+ require 'rake/testtask'
4
+ require 'bundler'
5
+
6
+ Bundler::GemHelper.install_tasks
7
+
8
+ Rake::TestTask.new(:test) do |test|
9
+ test.ruby_opts = ["-rubygems"] if defined? Gem
10
+ test.libs << "lib" << "test"
11
+ test.pattern = "test/**/*_test.rb"
12
+ end
13
+
14
+ task :default => :test
@@ -11,9 +11,9 @@ module Faraday
11
11
  env[:response].on_complete do |response|
12
12
  response[:body] = begin
13
13
  case response[:response_headers].values_at('content-type', 'Content-Type').first
14
- when /application\/json/
14
+ when /\/json/
15
15
  parse_json(response[:body])
16
- when /application\/xml/
16
+ when /\/xml/
17
17
  parse_xml(response[:body])
18
18
  else
19
19
  ''
@@ -1,3 +1,3 @@
1
1
  module FaradayMiddleware
2
- VERSION = "0.2.2"
2
+ VERSION = "0.2.3"
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: faraday_middleware
3
3
  version: !ruby/object:Gem::Version
4
- hash: 19
4
+ hash: 17
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 2
9
- - 2
10
- version: 0.2.2
9
+ - 3
10
+ version: 0.2.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Wynn Netherland
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-10-29 00:00:00 -07:00
18
+ date: 2010-11-08 00:00:00 -08:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency