From 31156dd482d8773401fb6e1391edf48eec91c0e7 Mon Sep 17 00:00:00 2001 From: Justin Mazzocchi <2831158+jzzocc@users.noreply.github.com> Date: Tue, 29 Sep 2020 23:49:04 -0700 Subject: [PATCH] Add order lost in refactoring --- DB/Sources/DB/Content/AccountRecord.swift | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/DB/Sources/DB/Content/AccountRecord.swift b/DB/Sources/DB/Content/AccountRecord.swift index 6d47dd2..0693838 100644 --- a/DB/Sources/DB/Content/AccountRecord.swift +++ b/DB/Sources/DB/Content/AccountRecord.swift @@ -81,7 +81,8 @@ extension AccountRecord { request(for: Self.hasMany( StatusRecord.self, through: Self.statusJoins.filter(AccountStatusJoin.Columns.collection == collection.rawValue), - using: AccountStatusJoin.status))) + using: AccountStatusJoin.status) + .order(StatusRecord.Columns.createdAt.desc))) } init(account: Account) {