From 899b60f7e64375249234e92f8d67320eaf91311a Mon Sep 17 00:00:00 2001 From: Johannes Findeisen Date: Wed, 23 Nov 2022 04:39:30 +0100 Subject: [PATCH] Some fix and 'maybe' an improvement --- fgg | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/fgg b/fgg index df67d15..db32e21 100755 --- a/fgg +++ b/fgg @@ -154,7 +154,7 @@ while photo_page <= page_count: str(flickr_photo_info['taken']))).hexdigest() digest = str(str(digest1) + str(digest2) + str(digest3) + str(digest4)) - digest = str(hex(crc32c.crc32c(bytes(digest, 'ascii')))).replace('0x', '') + digest = str(hex(crc32c(bytes(digest, 'ascii')))).replace('0x', '') photo['digest'] = digest # END ################################################################################## @@ -279,7 +279,10 @@ while photo_page <= page_count: # Remove all unneeded keys photo['sizes'][flickr_size].pop('media') photo['sizes'][flickr_size].pop('source') - photo['sizes'][flickr_size].pop('url') + # Do not remove the URL because you may want to use it on your website photo page. + # It makes sense to not delete it when not using the "delete" feature of fgg or when + # having a pro account. + #photo['sizes'][flickr_size].pop('url') Path('cache/' + flickr_photo.id).mkdir(parents=True, exist_ok=True) with open('cache/' + flickr_photo.id + '/meta.json', 'w') as f: