chat/message: Fix RecentActiveUsers sort order
authorAndrey Petrov <shazow@gmail.com>
Thu, 30 Jul 2020 16:02:07 +0000 (12:02 -0400)
committerGitHub <noreply@github.com>
Thu, 30 Jul 2020 16:02:07 +0000 (12:02 -0400)
chat/message/user.go

index 3f96e281bdeb74cfe5e3daa26c2128d1ec2e9503..d4cc304c539c995076dcc27e02dba1adefc84538 100644 (file)
@@ -262,7 +262,7 @@ func (a RecentActiveUsers) Less(i, j int) bool {
        if a[i].lastMsg.IsZero() {
                return a[i].joined.Before(a[j].joined)
        } else {
-               return a[i].lastMsg.After(a[j].lastMsg)
+               return a[i].lastMsg.Before(a[j].lastMsg)
        }
 
 }