From 29673bdfe88413b34a127530a1c07ab8480c4248 Mon Sep 17 00:00:00 2001 From: Joey Hines Date: Thu, 19 Jul 2018 22:05:23 -0500 Subject: [PATCH] Fixed addshop --- Geoffrey.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Geoffrey.py b/Geoffrey.py index 8c794d2..33197b1 100644 --- a/Geoffrey.py +++ b/Geoffrey.py @@ -109,16 +109,16 @@ async def addbase(ctx, x_pos: int, y_pos: int, z_pos: int, * args): async def addshop(ctx, x_pos: int, y_pos: int, z_pos: int, *args): ''' Adds your shop to the database. The name is optional. - ?addshop [Base Name] [X Coordinate] [Y Coordinate] [Z Coordinate] [Name] + ?addshop [Shop Name] [X Coordinate] [Y Coordinate] [Z Coordinate] [Name] ''' if len(args) > 0: name = args[0] else: - name = '{}\'s Shop'.database_interface.find_player_by_discord_uuid(ctx.message.author.id) + name = '{}\'s Shop'.format(database_interface.find_player_by_discord_uuid(ctx.message.author.id).name) try: - base = database_interface.add_shop(ctx.message.author.id, name, x_pos, y_pos, z_pos) + shop = database_interface.add_shop(ctx.message.author.id, name, x_pos, y_pos, z_pos) except LocationInitError: raise commands.UserInputError except LocationNameNotUniqueError: @@ -127,7 +127,7 @@ async def addshop(ctx, x_pos: int, y_pos: int, z_pos: int, *args): return await bot.say('{}, your shop named **{}** located at {} has been added' - ' to the database.'.format(ctx.message.author.mention, base.name, base.pos_to_str())) + ' to the database.'.format(ctx.message.author.mention, shop.name, shop.pos_to_str())) @bot.command(pass_context=True)