diff options
author | Konstantin Käfer <mail@kkaefer.com> | 2016-01-07 11:40:43 +0100 |
---|---|---|
committer | Konstantin Käfer <mail@kkaefer.com> | 2016-01-08 16:25:54 +0100 |
commit | a06f28ddb70cd1963076d6df2ef3716d45b7a13e (patch) | |
tree | 3a7f15ddd8ebb6d552e26005e1d8abc2c380e5fe /test/storage/server.js | |
parent | c5feadf0bd04d77335f56f79c1dea75a3c43c976 (diff) | |
download | qtlocation-mapboxgl-a06f28ddb70cd1963076d6df2ef3716d45b7a13e.tar.gz |
[core] only cache successful or NotFound responses
We don't want other types of error end up in our cache, since it'll likely evict perfectly good content.
Diffstat (limited to 'test/storage/server.js')
-rwxr-xr-x | test/storage/server.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/storage/server.js b/test/storage/server.js index a814ce15e6..5d547b1506 100755 --- a/test/storage/server.js +++ b/test/storage/server.js @@ -81,6 +81,10 @@ app.get('/revalidate-etag', function(req, res) { revalidateEtagCounter++; }); +app.get('/not-found', function(req, res) { + res.status(404).send('Not Found!'); +}); + app.get('/permanent-error', function(req, res) { res.status(500).send('Server Error!'); }); |