Skip to content

Commit c11b584

Browse files
committed
How about a proper middleware order?
Now it makes sense when headers are modified before storing them in cache.
1 parent faf319e commit c11b584

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/nanoc/github.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,12 @@ class Source < Nanoc::DataSource
4747

4848
def up
4949
stack = Faraday::RackBuilder.new do |builder|
50-
builder.use ModifyMaxAge, time: max_age
5150
builder.use Faraday::HttpCache,
5251
serializer: Marshal,
5352
shared_cache: false,
5453
store: Cache.new(tmp_dir),
5554
logger: verbose ? logger : nil
55+
builder.use ModifyMaxAge, time: max_age
5656
builder.use Faraday::Request::Retry,
5757
exceptions: [Octokit::ServerError]
5858
builder.use Octokit::Middleware::FollowRedirects

0 commit comments

Comments
 (0)