From 3ef24e86c8b875a302df86d95836d721e40c86ca Mon Sep 17 00:00:00 2001 From: Mark Veidemanis Date: Sat, 23 Apr 2022 11:53:30 +0100 Subject: [PATCH] Fix map command --- handler/ux/commands.py | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/handler/ux/commands.py b/handler/ux/commands.py index bdce2ce..ce0a627 100644 --- a/handler/ux/commands.py +++ b/handler/ux/commands.py @@ -494,7 +494,7 @@ class IRCCommands(object): @staticmethod def run(cmd, spl, length, authed, msg, agora, tx, ux): - if length == 2: + if length == 3: reference = spl[1] txid = spl[2] is_released = tx.release_map_trade(reference, txid) @@ -956,3 +956,17 @@ class IRCCommands(object): msg("Could not get bank details.") return msg(bank_details) + + class id(object): + name = "id" + authed = True + helptext = "Get the identity information of a user. Usage: id " + + @staticmethod + def run(cmd, spl, length, authed, msg, agora, tx, ux): + if length == 3: + platform = spl[1] + username = spl[2] + uid = tx.create_uid(platform, username) + first, last = tx.ux.verify.get_external_user_id_details(uid) + msg(f"Name: {first} {last}")