Updated docs and fixed settings api key issue
parent
65a594e876
commit
fd422657d0
|
@ -420,7 +420,8 @@ def restock(item_name, shop_name=None, discord_uuid=None, mc_uuid=None):
|
|||
:param shop_name: Shop the item is in, can be none if the only one location is owned by the user
|
||||
:param discord_uuid: Discord UUID
|
||||
:param mc_uuid: Minecraft UUID
|
||||
:return:
|
||||
:return: List of items updated
|
||||
:help: Restocks items matching the item name in your shop
|
||||
'''
|
||||
owner = get_player(discord_uuid, mc_uuid)
|
||||
shop = get_location(owner, shop_name, Shop)
|
||||
|
@ -430,3 +431,5 @@ def restock(item_name, shop_name=None, discord_uuid=None, mc_uuid=None):
|
|||
for item in items:
|
||||
item.date_restocked = datetime.datetime.now()
|
||||
item.save()
|
||||
|
||||
return objects_list_to_json(items)
|
||||
|
|
|
@ -61,7 +61,7 @@ class CommandAPI(View):
|
|||
|
||||
class SettingsAPI(View):
|
||||
def get(self, request):
|
||||
if check_token(request, command_perm=True):
|
||||
if check_token(request.GET, commands_perm=True):
|
||||
response = {
|
||||
"BOT_PREFIX": getattr(settings, 'GEOFFREY_BOT_PREFIX', '?'),
|
||||
"ERROR_USERS": getattr(settings, 'GEOFFREY__BOT_ERROR_USERS', []),
|
||||
|
|
Loading…
Reference in New Issue