plugins/QuoteGrabs: Order the quotes in reverse chronological order.

This commit is contained in:
James Vega 2005-08-04 17:53:29 +00:00
parent cede4a4a97
commit a035492295
2 changed files with 3 additions and 3 deletions

View File

@ -128,7 +128,7 @@ class SqliteQuoteGrabsDB(object):
cursor = db.cursor()
cursor.execute("""SELECT id, quote FROM quotegrabs
WHERE nickeq(nick, %s)
ORDER BY id ASC""", nick)
ORDER BY id DESC""", nick)
return [QuoteGrabsRecord(id, text=quote)
for (id, quote) in cursor.fetchall()]

View File

@ -60,7 +60,7 @@ class QuoteGrabsTestCase(ChannelPluginTestCase):
prefix=testPrefix))
self.assertNotError('grab foo')
self.assertResponse('quotegrabs list foo',
'#1: test and #2: %s...' %\
'#2: %s... and #1: test' %\
('a'*43)) # 50 - length of "#2: ..."
def testDuplicateGrabs(self):