From ea0d4eb0c7bf51f9ce46b00874e909fdce0847f4 Mon Sep 17 00:00:00 2001 From: Reinier Balt Date: Thu, 30 Aug 2012 10:57:16 +0200 Subject: [PATCH] invalidate cache of todo every day so stalenes and due date can be regenerated --- app/views/todos/_todo.html.erb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/views/todos/_todo.html.erb b/app/views/todos/_todo.html.erb index 8a40a613..7a9ee02a 100644 --- a/app/views/todos/_todo.html.erb +++ b/app/views/todos/_todo.html.erb @@ -7,7 +7,9 @@ parameters += "&_tag_name=#{@tag_name}" if @source_view == 'tag' @z_index_counter = @z_index_counter - 1 # for IE z-index bug @rec_depth=0 # to prevent stack overflow on large dependency trees, see _successor.html.erb -cache todo do +# invalidate the cache every day because of staleness or +# rendering of "due in x days" that change without touching updated at of the todo +cache [todo, current_user.date.strftime("%Y%m%d")] do %>