prismicio-community / php-kit

Community maintained development kit for Prismic and the PHP language
https://prismic.io
Other
109 stars 83 forks source link

ttl vs absolute timestamp #64

Closed vancromp closed 10 years ago

vancromp commented 10 years ago

Hello,

I think there is a little problem at line 258. The third argument of cache->set() is a ttl, so $expiration must be set to a ttl, and not to a absolute timestamp. This can lead to caching problems, because ttl is set to 2014 - 1970 + 10 years (from cache-control header) = 54 years, that is a too high ttl for some caching systems.

Cheers,

Pierre

srenault commented 10 years ago

Thanks!