diff options
author | Thomas Pointhuber <thomas.pointhuber@gmx.at> | 2014-03-15 19:31:34 +0100 |
---|---|---|
committer | Thomas Pointhuber <thomas.pointhuber@gmx.at> | 2014-03-15 19:31:34 +0100 |
commit | ef2b1b7515fbc029d566ab1afb80429007983fbb (patch) | |
tree | 87ed983d1df4bee2a35a887178ffceba9a3e586e /searx/webapp.py | |
parent | 5538c6771abacb9dab504fa7da0052c443b14f13 (diff) | |
download | searxng-ef2b1b7515fbc029d566ab1afb80429007983fbb.tar.gz searxng-ef2b1b7515fbc029d566ab1afb80429007983fbb.zip |
fix little bug
Diffstat (limited to 'searx/webapp.py')
-rw-r--r-- | searx/webapp.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/searx/webapp.py b/searx/webapp.py index 5cc059044..54061a462 100644 --- a/searx/webapp.py +++ b/searx/webapp.py @@ -159,8 +159,8 @@ def index(): # TODO, check if timezone is calculated right if 'publishedDate' in result: - if result['publishedDate'].date() == datetime.now().date(): - timedifference = datetime.now()-result['publishedDate'] + if result['publishedDate'] >= datetime.now() - timedelta(days=1): + timedifference = datetime.now() - result['publishedDate'] minutes = int((timedifference.seconds/60)%60) hours = int(timedifference.seconds/60/60) if hours == 0: |