fix formatting of json output, bump version

This commit is contained in:
William Kray 2020-12-22 16:00:34 -08:00
parent 28afea5269
commit b92839e0ba
2 changed files with 4 additions and 4 deletions

View File

@ -100,7 +100,7 @@ class Invite(Plugin):
return None
# this isn't formatted nicely but i don't really care that much
await evt.respond(f"Status of token {token}: {json.dumps(resp_json, indent=4)}")
await evt.respond(f"Status of token {token}: \n<pre><code format=json>{json.dumps(resp_json, indent=4)}</code></pre>", allow_html=True)
@invite.subcommand("revoke", help="Disable an existing invite token.")
@command.argument("token", "Token", pass_raw=True, required=True)
@ -127,7 +127,7 @@ class Invite(Plugin):
return None
# this isn't formatted nicely but i don't really care that much
await evt.respond(f"{json.dumps(resp_json, indent=4)}")
await evt.respond(f"<pre><code format=json>{json.dumps(resp_json, indent=4)}</code></pre>", allow_html=True)
@invite.subcommand("list", help="List all tokens that have been generated.")
async def list(self, evt: MessageEvent) -> None:
@ -148,4 +148,4 @@ class Invite(Plugin):
return None
# this isn't formatted nicely but i don't really care that much
await evt.respond(f"{resp_json}")
await evt.respond(f"<pre><code format=json>{json.dumps(resp_json, indent=4)}</code></pre>", allow_html=True)

View File

@ -1,6 +1,6 @@
maubot: 0.1.0
id: org.jobmachine.invitebot
version: 0.0.3
version: 0.1.0
license: MIT
modules:
- invite