This commit is contained in:
Simon
2018-12-06 10:05:35 -05:00
parent d4fd764536
commit e89eb6e3e0
2 changed files with 4 additions and 3 deletions

View File

@@ -388,7 +388,7 @@ class Database:
cursor.execute("SELECT id, website_id, url, priority, callback_type, callback_args " +
"FROM Queue WHERE assigned_crawler is NULL " +
("AND url LIKE 'ftp%' " if ftp else "") +
("AND url LIKE 'ftp%' " if ftp else "AND url LIKE 'http%' ") +
"ORDER BY priority DESC, Queue.id " +
"ASC LIMIT 1")
task = cursor.fetchone()