From 07841bd2ec86cb667aea633de5dcb068751e64d3 Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Mon, 15 Oct 2018 17:29:05 +0200 Subject: Friends list (beginning) --- shardweb/lib/views/identity_view.ex | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'shardweb/lib/views/identity_view.ex') diff --git a/shardweb/lib/views/identity_view.ex b/shardweb/lib/views/identity_view.ex index 1844ce8..86423b2 100644 --- a/shardweb/lib/views/identity_view.ex +++ b/shardweb/lib/views/identity_view.ex @@ -18,4 +18,9 @@ defmodule ShardWeb.IdentityView do end end) end + + def is_friend(conn, pk) do + fd = SApp.Directory.friends_dir(conn.assigns.pk) + SApp.Directory.find(fd, %SApp.Identity.Manifest{pk: pk}) != nil + end end -- cgit v1.2.3