Skip to content

Commit

Permalink
Fix default writePolicyFn
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesplease committed Mar 22, 2020
1 parent 0a4f960 commit dd63180
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/response-cache.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ let readPolicyFn = () => true;

// By default server errors are not cached, but every other successful response is.
let writePolicyFn = res => {
if (res.code >= 500) {
if (res.status >= 500) {
return false;
} else {
return true;
Expand Down

0 comments on commit dd63180

Please sign in to comment.