Nicer account output - toot - Unnamed repository; edit this file 'description' to name the repository.
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) LICENSE
---
(DIR) commit 661d35675a87fb7cca59be4d7ff82ff3ca93f25d
(DIR) parent 6766cf83b4fcd2af297906de4213b9dc5923049d
(HTM) Author: Ivan Habunek <ivan@habunek.com>
Date: Sun, 7 May 2017 10:42:31 +0200
Nicer account output
Diffstat:
toot/commands.py | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
---
(DIR) diff --git a/toot/commands.py b/toot/commands.py
@@ -288,10 +288,11 @@ def _find_account(app, user, account_name):
def _print_account(account):
print("{} {}".format(green("@" + account['acct']), account['display_name']))
- if account['note']:
+ note = BeautifulSoup(account['note'], "html.parser").get_text()
+
+ if note:
print("")
- note = BeautifulSoup(account['note'], "html.parser")
- print("\n".join(wrap(note.get_text())))
+ print("\n".join(wrap(note)))
print("")
print("ID: " + green(account['id']))