feat: support etag

This commit is contained in:
DIYgod
2020-09-29 18:53:24 +08:00
parent 6676fefe1a
commit 6ec230f58f
4 changed files with 28 additions and 17 deletions

View File

@@ -23,4 +23,8 @@ module.exports = async (ctx, next) => {
}
ctx.state.debuged = true;
if (ctx.status === 304) {
ctx.debug.etag++;
}
};