diff options
author | Bastien Nocera <hadess@hadess.net> | 2021-01-12 12:17:26 +0100 |
---|---|---|
committer | Bastien Nocera <hadess@hadess.net> | 2021-01-12 15:11:55 +0100 |
commit | bb808529793a47c6458cc48e39630e35155238e0 (patch) | |
tree | dd792d9b591c674e2d8fcb37a806316fbc5ad469 | |
parent | 86eaa6d95fc2f4184be024f01fd2465dc0ede004 (diff) | |
download | libgweather-bb808529793a47c6458cc48e39630e35155238e0.tar.gz |
gweather: Require an app-id to run gweather_info_update()
-rw-r--r-- | libgweather/gweather-weather.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libgweather/gweather-weather.c b/libgweather/gweather-weather.c index e5548a4..c505ccd 100644 --- a/libgweather/gweather-weather.c +++ b/libgweather/gweather-weather.c @@ -690,6 +690,12 @@ gweather_info_update (GWeatherInfo *info) { gboolean ok; + if (info->providers == GWEATHER_PROVIDER_NONE) + return; + + g_return_if_fail (info->application_id != NULL); + g_return_if_fail (g_application_id_is_valid (info->application_id)); + /* Update in progress */ if (!requests_init (info)) return ; |