forked from blizzthewolf/SeaCogs
fix(pterodactyl): make sure views get removed properly
This commit is contained in:
parent
df92bc34cc
commit
80cb729e72
1 changed files with 3 additions and 3 deletions
|
@ -128,7 +128,7 @@ class Pterodactyl(commands.Cog):
|
||||||
if view.result is True:
|
if view.result is True:
|
||||||
await message.edit(content="Sending websocket command to start server...", view=None)
|
await message.edit(content="Sending websocket command to start server...", view=None)
|
||||||
await self.websocket.send(json.dumps({"event": "set state", "args": ["start"]}))
|
await self.websocket.send(json.dumps({"event": "set state", "args": ["start"]}))
|
||||||
await message.edit(content="Server starting...")
|
await message.edit(content="Server starting...", view=None)
|
||||||
else:
|
else:
|
||||||
await message.edit(content="Cancelled.", view=None)
|
await message.edit(content="Cancelled.", view=None)
|
||||||
|
|
||||||
|
@ -146,7 +146,7 @@ class Pterodactyl(commands.Cog):
|
||||||
if view.result is True:
|
if view.result is True:
|
||||||
await message.edit(content="Sending websocket command to stop server...", view=None)
|
await message.edit(content="Sending websocket command to stop server...", view=None)
|
||||||
await self.websocket.send(json.dumps({"event": "set state", "args": ["stop"]}))
|
await self.websocket.send(json.dumps({"event": "set state", "args": ["stop"]}))
|
||||||
await message.edit(content="Server stopping...")
|
await message.edit(content="Server stopping...", view=None)
|
||||||
else:
|
else:
|
||||||
await message.edit(content="Cancelled.", view=None)
|
await message.edit(content="Cancelled.", view=None)
|
||||||
|
|
||||||
|
@ -162,7 +162,7 @@ class Pterodactyl(commands.Cog):
|
||||||
if view.result is True:
|
if view.result is True:
|
||||||
await message.edit(content="Sending websocket command to restart server...", view=None)
|
await message.edit(content="Sending websocket command to restart server...", view=None)
|
||||||
await self.websocket.send(json.dumps({"event": "set state", "args": ["restart"]}))
|
await self.websocket.send(json.dumps({"event": "set state", "args": ["restart"]}))
|
||||||
await message.edit(content="Server restarting...")
|
await message.edit(content="Server restarting...", view=None)
|
||||||
else:
|
else:
|
||||||
await message.edit(content="Cancelled.", view=None)
|
await message.edit(content="Cancelled.", view=None)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue