Page cached did not remove

This commit is contained in:
斟酌 鵬兄 2016-12-21 21:36:26 +08:00
parent 3a3a22b37a
commit 10f1563c4a

View File

@ -23,10 +23,11 @@ class PageCache
setInterval( () => { setInterval( () => {
var d = new Date().getTime(); var d = new Date().getTime();
for( var i in this.cache ) for( let store of this.cache )
for( var i in store )
{ {
var c = this.cache[ i ]; var c = store[ i ];
if( c.ttl < d ) delete this.cache[ i ]; if( c.ttl < d ) delete store[ i ];
} }
for( var i in this.excepts ) for( var i in this.excepts )