mirror of
https://github.com/moparisthebest/mailcatcher
synced 2024-12-22 07:18:53 -05:00
Merge pull request #184 from captbaritone/patch-1
Ensure messages are shown in the order they were recieved
This commit is contained in:
commit
e703dbcf13
@ -69,7 +69,7 @@ module MailCatcher::Mail extend self
|
||||
end
|
||||
|
||||
def messages
|
||||
@messages_query ||= db.prepare "SELECT id, sender, recipients, subject, size, created_at FROM message ORDER BY created_at ASC"
|
||||
@messages_query ||= db.prepare "SELECT id, sender, recipients, subject, size, created_at FROM message ORDER BY created_at, id ASC"
|
||||
@messages_query.execute.map do |row|
|
||||
Hash[row.fields.zip(row)].tap do |message|
|
||||
message["recipients"] &&= ActiveSupport::JSON.decode message["recipients"]
|
||||
|
Loading…
Reference in New Issue
Block a user