async-http-faraday 0.17.0 → 0.18.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/changes.md +17 -0
- data/lib/async/http/faraday/clients.rb +2 -2
- data/lib/async/http/faraday/version.rb +1 -1
- data.tar.gz.sig +0 -0
- metadata +3 -2
- metadata.gz.sig +1 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7b306179751e2a8f56e9f63b68b243f8ae504b8c7a79f2c00ecd98fc1e09d9ba
|
4
|
+
data.tar.gz: c5aef891d4ba786d2e489c847c021a00bb47c8b0096ad07b595184bf8cd96caf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2faccb555f15488e99cc9f3b774dd9aae4eb9b3dac432623a85cf5c85019fa223cf0fe3538fb1e82cef67400f6d4ec86fc41ec8530a95effc69364fa50a99bf3
|
7
|
+
data.tar.gz: 4ea301d64d6bd6716eae5f7bbdb6569a31a4d51b9ac023a30f153ff248e87420c454966fb05cecd44acfad0a614690ada231b9d4ef6508f4ec53c4b87ee24a07
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/changes.md
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
# v0.18.0
|
2
|
+
|
3
|
+
## Config Block
|
4
|
+
|
5
|
+
The `config_block` provided to the adapter must now return `nil`, `client` or a middleware wrapper around `client`.
|
6
|
+
|
7
|
+
```ruby
|
8
|
+
Faraday.new do |builder|
|
9
|
+
builder.adapter :async_http do |client|
|
10
|
+
# Option 1 (same as returning `nil`), use client as is:
|
11
|
+
client # Use `client` as is.
|
12
|
+
|
13
|
+
# Option 2, wrap client in a middleware:
|
14
|
+
Async::HTTP::Middleware::LocationRedirector.new(client)
|
15
|
+
end
|
16
|
+
end
|
17
|
+
```
|
@@ -38,8 +38,8 @@ module Async
|
|
38
38
|
# @parameter endpoint [IO::Endpoint::Generic] The endpoint to create the client for.
|
39
39
|
def make_client(endpoint)
|
40
40
|
client = Client.new(endpoint, **@options)
|
41
|
-
|
42
|
-
return client
|
41
|
+
|
42
|
+
return @block&.call(client) || client
|
43
43
|
end
|
44
44
|
|
45
45
|
# Get a client for the given endpoint.
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: async-http-faraday
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.18.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Samuel Williams
|
@@ -46,7 +46,7 @@ cert_chain:
|
|
46
46
|
Q2K9NVun/S785AP05vKkXZEFYxqG6EW012U4oLcFl5MySFajYXRYbuUpH6AY+HP8
|
47
47
|
voD0MPg1DssDLKwXyt1eKD/+Fq0bFWhwVM/1XiAXL7lyYUyOq24KHgQ2Csg=
|
48
48
|
-----END CERTIFICATE-----
|
49
|
-
date: 2024-08-
|
49
|
+
date: 2024-08-17 00:00:00.000000000 Z
|
50
50
|
dependencies:
|
51
51
|
- !ruby/object:Gem::Dependency
|
52
52
|
name: async-http
|
@@ -82,6 +82,7 @@ executables: []
|
|
82
82
|
extensions: []
|
83
83
|
extra_rdoc_files: []
|
84
84
|
files:
|
85
|
+
- changes.md
|
85
86
|
- examples/topics.rb
|
86
87
|
- lib/async/http/faraday.rb
|
87
88
|
- lib/async/http/faraday/adapter.rb
|
metadata.gz.sig
CHANGED
@@ -1,2 +1 @@
|
|
1
|
-
|
2
|
-
\8w���Q�A�⛦�h)�D3��g�Lڝ\�iT��\��S����O�7Y^O}`w�<p��?��s��-��g�g�8��m�*�
|
1
|
+
y� �*��F�������
|