From 2def874ffd4d6e7fe8731e5e2e826d789097a7f4 Mon Sep 17 00:00:00 2001 From: zmagod Date: Tue, 5 Jun 2018 09:44:03 +0200 Subject: [PATCH] fixes project duplication [fixes SCI-2486] --- app/models/user.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/user.rb b/app/models/user.rb index 58eb08a15..9e953670e 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -359,7 +359,7 @@ class User < ApplicationRecord { created_at: :desc } end - result.where(archived: false).order(sort) + result.where(archived: false).distinct.order(sort) end # Finds all activities of user that is assigned to project. If user