gs-loading-page: Update software cache on first run

Currently, the software cache is only updated on startup if it’s empty.
However, this is not helpful in situations where the cache is present
but very old when gnome-software is first started. This can happen on
machines shipped with Endless OS (which pre-seeds the software cache)
which have sat in storage for a while before being booted for the first
time by their user. In that situation, old apps would be shown, which is
confusing and not a good user experience.

As a compromise, update the app cache if it’s older than 24h when
gnome-software is first started. On subsequent starts, revert to the old
behaviour of only updating the cache if it’s missing.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
1 job for load-data-on-first-startup in 15 minutes and 15 seconds (queued for 1 second)
Status Job ID Name Coverage
  Build
passed #355099
build-gnome-software

00:15:15