From 8acc6b73740c36964374fb98485898fce585eeb9 Mon Sep 17 00:00:00 2001 From: Ben Kurtovic Date: Mon, 8 Sep 2014 01:39:21 -0500 Subject: [PATCH] Pluralize queries; clean up duplication. --- templates/index.mako | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/templates/index.mako b/templates/index.mako index 48b0b21..41aef23 100644 --- a/templates/index.mako +++ b/templates/index.mako @@ -142,12 +142,15 @@ % if result:
+ Results % if result.cached: - Results cachedTo save time (and money), this tool will retain the results of checks for up to 72 hours. This includes the URLs of the checked sources, but neither their content nor the content of the article. Future checks on the same page (assuming it remains unchanged) will not involve additional search queries, but a fresh comparison against the source URL will be made. If the page is modified, a new check will be run. from ${result.cache_age} ago. Originally generated in ${round(result.time, 3)} seconds using ${result.queries} queries. - % elif query.action == "search": - Results generated in ${round(result.time, 3)} seconds using ${result.queries} queries. + cachedTo save time (and money), this tool will retain the results of checks for up to 72 hours. This includes the URLs of the checked sources, but neither their content nor the content of the article. Future checks on the same page (assuming it remains unchanged) will not involve additional search queries, but a fresh comparison against the source URL will be made. If the page is modified, a new check will be run. from ${result.cache_age} ago. Originally + % endif + generated in ${round(result.time, 3)} + % if query.action == "search": + seconds using ${result.queries} quer${"y" if result.queries == 1 else "ies"}. % else: - Results generated in ${round(result.time, 3)} seconds. + seconds. % endif