From e888ee88da0782ffd657362c57a706e32c20adee Mon Sep 17 00:00:00 2001 From: Bofh Date: Mon, 8 Feb 2021 11:06:51 +0100 Subject: [PATCH] Shorten the IG url as it is not clickable either + bug fix --- igmirror.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/igmirror.py b/igmirror.py index 7149b0d..49de0bc 100644 --- a/igmirror.py +++ b/igmirror.py @@ -282,10 +282,9 @@ def pixelfed_setpic(acc_id, pic_url, count=0): def pixelfed_setinfo(acc_id, bio, website, count=0): accdata = db_get('accounts', acc_id) - name = accdata['name'] + name = accdata['name'] + ' [Mirror]' if count == 0: - bio = 'Mirrored from Instagram: https://www.instagram.com/{} | {}'.format(acc_id, bio) - name = accdata['name'] + ' [Mirror]' + bio = 'Mirrored from Instagram: instagram.com/{} | {}'.format(acc_id, bio) count += 1 pixelfed_login(acc_id) @@ -294,7 +293,7 @@ def pixelfed_setinfo(acc_id, bio, website, count=0): _, _token = pixelfed_token_url('/settings/home', accdata['cookie']) r = requests.post( 'https://'+config()['instance']+'/settings/home',\ data={ - '_token': _token, 'name': accdata['name'], + '_token': _token, 'name': name, 'website': website, 'bio': bio, 'language': 'en' }, cookies=accdata['cookie']