Fix a bug in the queue query.

This commit is contained in:
yackob03 2013-10-20 03:06:11 -04:00
parent cf1b545dee
commit f80c9255e8

View file

@ -30,8 +30,8 @@ class WorkQueue(object):
minutes. minutes.
""" """
now = datetime.now() now = datetime.now()
available_or_expired = (QueueItem.available == True | available_or_expired = ((QueueItem.available == True) |
QueueItem.processing_expires <= now) (QueueItem.processing_expires <= now))
# TODO the query and the update should be atomic, but for now we only # TODO the query and the update should be atomic, but for now we only
# have one worker. # have one worker.