mirror of https://gitlab.com/bashrc2/epicyon
Fix tests
parent
579a9e88dd
commit
11995eccb4
6
inbox.py
6
inbox.py
|
@ -262,9 +262,11 @@ def _store_last_post_id(base_dir: str, nickname: str, domain: str,
|
||||||
post_id = remove_id_ending(post_json_object['id'])
|
post_id = remove_id_ending(post_json_object['id'])
|
||||||
if not actor:
|
if not actor:
|
||||||
return
|
return
|
||||||
lastpost_dir = acct_dir(base_dir, nickname, domain) + '/lastpost'
|
account_dir = acct_dir(base_dir, nickname, domain)
|
||||||
|
lastpost_dir = account_dir + '/lastpost'
|
||||||
if not os.path.isdir(lastpost_dir):
|
if not os.path.isdir(lastpost_dir):
|
||||||
os.mkdir(lastpost_dir)
|
if os.path.isdir(account_dir):
|
||||||
|
os.mkdir(lastpost_dir)
|
||||||
actor_filename = lastpost_dir + '/' + actor.replace('/', '#')
|
actor_filename = lastpost_dir + '/' + actor.replace('/', '#')
|
||||||
try:
|
try:
|
||||||
with open(actor_filename, 'w+', encoding='utf-8') as fp_actor:
|
with open(actor_filename, 'w+', encoding='utf-8') as fp_actor:
|
||||||
|
|
|
@ -891,9 +891,12 @@ def _get_like_icon_html(nickname: str, domain_full: str,
|
||||||
'/users/' + nickname + '?likers=' + likers_post_id
|
'/users/' + nickname + '?likers=' + likers_post_id
|
||||||
|
|
||||||
# show the number of likes next to icon
|
# show the number of likes next to icon
|
||||||
|
show_liked_str = 'Show who liked this post'
|
||||||
|
if translate.get(show_liked_str):
|
||||||
|
show_liked_str = translate[show_liked_str]
|
||||||
like_str += '<label class="likesCount">'
|
like_str += '<label class="likesCount">'
|
||||||
like_str += '<a href="' + likers_screen_link + '" ' + \
|
like_str += '<a href="' + likers_screen_link + '" ' + \
|
||||||
'title="' + translate['Show who liked this post'] + \
|
'title="' + show_liked_str + \
|
||||||
'" tabindex="10">'
|
'" tabindex="10">'
|
||||||
like_str += like_count_str.replace('(', '').replace(')', '').strip()
|
like_str += like_count_str.replace('(', '').replace(')', '').strip()
|
||||||
like_str += '</a></label>\n'
|
like_str += '</a></label>\n'
|
||||||
|
|
Loading…
Reference in New Issue