diff options
author | Alex Auvolat <alex@adnab.me> | 2018-11-02 11:22:28 +0100 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2018-11-02 11:22:28 +0100 |
commit | 3baa53f1da7f581619b066832b8303efbe9a46ba (patch) | |
tree | d6b49bd09fa915b93e13f3a03febc7fb1b38e9a4 /shardweb/lib/controllers | |
parent | 80200dc43f271938fb14ec4eb4712e8dd7375aeb (diff) | |
download | shard-3baa53f1da7f581619b066832b8303efbe9a46ba.tar.gz shard-3baa53f1da7f581619b066832b8303efbe9a46ba.zip |
Remove friends list ; add some links
Diffstat (limited to 'shardweb/lib/controllers')
-rw-r--r-- | shardweb/lib/controllers/identity_controller.ex | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/shardweb/lib/controllers/identity_controller.ex b/shardweb/lib/controllers/identity_controller.ex index d1c6886..962a888 100644 --- a/shardweb/lib/controllers/identity_controller.ex +++ b/shardweb/lib/controllers/identity_controller.ex @@ -25,40 +25,6 @@ defmodule ShardWeb.IdentityController do end end - def view_post(conn, opts) do - IO.puts(inspect opts) - {:ok, pk} = Base.decode16(opts["pk"]) - manifest = %SApp.Identity.Manifest{pk: pk} - nick = SApp.Identity.get_nick pk - shard = manifest |> SData.term_hash - pid = Shard.Manager.find_proc shard - - if opts["add_friend"] == "true" do - friend_list = SApp.Directory.friends_dir(conn.assigns.pk) - name = nick <> " " <> Shard.Keys.pk_display(pk) - SApp.Directory.add_file(friend_list, name, manifest) - end - - if opts["rm_friend"] == "true" do - friend_list = SApp.Directory.friends_dir(conn.assigns.pk) - name = SApp.Directory.find(friend_list, manifest) - if name != nil do - SApp.Directory.rm_file(friend_list, name) - end - end - - if pid == nil do - render conn, ShardWeb.ErrorView, "404.html" - else - render conn, "view.html", - view_pk: pk, - view_nick: SApp.Identity.get_nick(pk), - shard: shard, - pid: pid - end - #TODO - end - def update(conn, params) do pid = SApp.Identity.find_proc(conn.assigns.pk) info = SApp.Identity.get_info(pid) |