weather: minor formatting changes in checkUpdate()

Origin commit data
------------------
Branch: ni/coolstream
Commit: c09903b255
Author: vanhofen <vanhofen@gmx.de>
Date: 2024-01-08 (Mon, 08 Jan 2024)

Origin message was:
------------------
- weather: minor formatting changes in checkUpdate()

------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
vanhofen
2024-01-08 21:48:28 +01:00
parent b9361f5e65
commit 1aa01a475d

View File

@@ -82,9 +82,10 @@ void CWeather::setCoords(std::string new_coords, std::string new_city)
bool CWeather::checkUpdate(bool forceUpdate)
{
time_t current_time = time(NULL);
if (forceUpdate || (difftime(current_time, last_time) > (UPDATE_CYCLE * 60)))
return GetWeatherDetails();
else
return false;
}