Fix maxtime caching