mirror of
https://github.com/suyiiyii/nonebot-bison.git
synced 2025-06-05 19:36:43 +08:00
update post style
This commit is contained in:
parent
f9a9267895
commit
37c3751f0a
@ -18,7 +18,7 @@ class Post:
|
|||||||
msgs = []
|
msgs = []
|
||||||
text = '来源: {}'.format(self.target_type)
|
text = '来源: {}'.format(self.target_type)
|
||||||
if self.target_name:
|
if self.target_name:
|
||||||
text += '\n{}'.format(self.target_name)
|
text += ' {}'.format(self.target_name)
|
||||||
if self.text:
|
if self.text:
|
||||||
text += '\n{}'.format(self.text)
|
text += '\n{}'.format(self.text)
|
||||||
if plugin_config.hk_reporter_use_pic:
|
if plugin_config.hk_reporter_use_pic:
|
||||||
@ -35,8 +35,9 @@ class Post:
|
|||||||
return msgs
|
return msgs
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
return 'type: {}\ntext: {}\nurl: {}\npic: {}'.format(
|
return 'type: {}\nfrom: {}\ntext: {}\nurl: {}\npic: {}'.format(
|
||||||
self.target_type,
|
self.target_type,
|
||||||
|
self.target_name,
|
||||||
self.text,
|
self.text,
|
||||||
self.url,
|
self.url,
|
||||||
', '.join(map(lambda x: 'b64img' if x.startswith('base64') else x, self.pics))
|
', '.join(map(lambda x: 'b64img' if x.startswith('base64') else x, self.pics))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user