additional changes to render thumbs directly from planespotters

This commit is contained in:
kx1t
2025-03-17 01:53:09 +01:00
parent 3fb048e1f1
commit ee06e6d08e
2 changed files with 2 additions and 1 deletions

View File

@@ -58,7 +58,7 @@
#
# HISTTIME: number of days shown in the history section of the website:
HISTTIME=7
HISTTIME=14
#
# COLLAPSEWITHIN: number of seconds between end time of an entry to start time of new entry within which

View File

@@ -200,6 +200,7 @@ GET_PS_PHOTO () {
echo "$link" > "/usr/share/planefence/persist/planepix/cache/$1.link"
echo "$thumb" > "/usr/share/planefence/persist/planepix/cache/$1.thumb.link"
echo "$link"
touch -d "+$((HISTTIME+1)) days" "/usr/share/planefence/persist/planepix/cache/$1.link" "/usr/share/planefence/persist/planepix/cache/$1.thumb.link"
echo "pf - $(date) - $(( $(date +%s) - starttime )) secs - $1 - picture retrieved from planespotters.net" >> /tmp/getpi.log
else
# If we don't have a link, let's clear the cache and return an empty string