on master help sign in
fix little bug
commitef2b1b7515fbc029d566ab1afb80429007983fbb authorThomas Pointhuber <thomas.pointhuber@gmx.at> dateSat 15 Mar 2014, 19:31 (13 years ago) parent5538c67
1 file changed+2−2
searx/webapp.py+2−2
searx/webapp.py+2−2
@@ -159,8 +159,8 @@ def index():
159159
160160 # TODO, check if timezone is calculated right
161161 if 'publishedDate' in result:
162− if result['publishedDate'].date() == datetime.now().date():
163− timedifference = datetime.now()-result['publishedDate']
162+ if result['publishedDate'] >= datetime.now() - timedelta(days=1):
163+ timedifference = datetime.now() - result['publishedDate']
164164 minutes = int((timedifference.seconds/60)%60)
165165 hours = int(timedifference.seconds/60/60)
166166 if hours == 0: