Comments (3)
I'm having trouble seeing this happening. Does this happen for requests to the same file? Different files? Files of the same type? When there's a global default? When there's an extension specific default?
I've ran a ton of tests and can't seem to recreate this bug. I need more info, or some kind of an example.
from mccs.
It's right there in the code:
$cache_control = $self->defaults->{cache_control}
if $self->defaults && defined $self->defaults->{cache_control};
# ...
$cache_control = $self->types->{$ext}->{cache_control}
if $self->types && $self->types->{$ext} && defined $self->types->{$ext}->{cache_control};
# ...
unshift(@$cache_control, 'max-age='.$valid_for)
if $cache;
$self->defaults->{cache_control}
is an array ref, which you define as $cache_control
. Same thing for $self->types->{$ext}->{cache_control}
. In either case, you then unshift the array ref with a "max-age" param. This is the single reference to the default cache_control, not a copy.
I really don't know how to explain it any further without insulting your intelligence.
from mccs.
I saw the problem in the code, realized it's wrong, but for some reason the tests did not display that behavior, though I might be missing something.
Anyway, bug fixed in new version (will release later today), thanks for reporting.
from mccs.
Related Issues (2)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mccs.