Cosmetic: strip name/topic whitespace, readable alias link in add confirmation; v2.0.5
This commit is contained in:
parent
1509b0925e
commit
394747e9de
3 changed files with 6 additions and 5 deletions
|
|
@ -1,6 +1,6 @@
|
|||
maubot: 0.1.0
|
||||
id: nl.roomsoverview
|
||||
version: 2.0.4
|
||||
version: 2.0.5
|
||||
license: MIT
|
||||
modules:
|
||||
- roomsoverview
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -181,9 +181,9 @@ class RoomsOverviewPlugin(Plugin):
|
|||
pass
|
||||
|
||||
return {
|
||||
"name": (name or {}).get("name", "") or "",
|
||||
"topic": (topic or {}).get("topic", "") or "",
|
||||
"alias": (alias or {}).get("alias", "") or "",
|
||||
"name": ((name or {}).get("name", "") or "").strip(),
|
||||
"topic": ((topic or {}).get("topic", "") or "").strip(),
|
||||
"alias": ((alias or {}).get("alias", "") or "").strip(),
|
||||
"members": members,
|
||||
}
|
||||
|
||||
|
|
@ -371,9 +371,10 @@ class RoomsOverviewPlugin(Plugin):
|
|||
evt.sender,
|
||||
int(time.time()),
|
||||
)
|
||||
target = info["alias"] or room_id
|
||||
await evt.reply(
|
||||
f"Room toegevoegd: **{info['name'] or room_id}** "
|
||||
f"(matrix.to/#/{quote(info['alias'] or room_id, safe='!')})"
|
||||
f"([{target}](https://matrix.to/#/{quote(target, safe='!')}))"
|
||||
)
|
||||
|
||||
@handle_rooms.subcommand(name="remove", help="Verwijder een room (moderator+)")
|
||||
|
|
|
|||
Loading…
Reference in a new issue