From c0185897495f40fa3264aaa3cb57071daeb214ad Mon Sep 17 00:00:00 2001 From: kolaente Date: Wed, 12 Sep 2018 21:45:30 +0200 Subject: [PATCH] fixed lint + fmt --- models/list_rights.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/models/list_rights.go b/models/list_rights.go index 977350b3..e3eb5ad7 100644 --- a/models/list_rights.go +++ b/models/list_rights.go @@ -89,9 +89,9 @@ func (l *List) checkListUserRight(user *User, r UserRight) bool { Join("LEFT", []string{"users_namespace", "un"}, "un.namespace_id = l.namespace_id"). Join("LEFT", []string{"users_list", "ul"}, "ul.list_id = l.id"). Join("LEFT", []string{"namespaces", "n"}, "n.id = l.namespace_id"). - Where("((ul.user_id = ? AND ul.right = ?) " + - "OR (un.user_id = ? AND un.right = ?) " + - "OR n.owner_id = ?)" + + Where("((ul.user_id = ? AND ul.right = ?) "+ + "OR (un.user_id = ? AND un.right = ?) "+ + "OR n.owner_id = ?)"+ "AND l.id = ?", user.ID, r, user.ID, r, user.ID, l.ID). Exist(&List{})