summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Nocera <hadess@hadess.net>2021-01-12 17:53:19 +0100
committerBastien Nocera <hadess@hadess.net>2021-01-13 01:37:24 +0100
commit1ebc7399c3d77265ea0cfc88e23b8e9a26b5b0f8 (patch)
tree285ea021440befa4f2bf7217444cebc9622308b5
parent6e46db89d46178615ae17e5b6f560677e8679574 (diff)
downloadlibgweather-1ebc7399c3d77265ea0cfc88e23b8e9a26b5b0f8.tar.gz
gweather: Fix _gweather_info_new_clone() throwing warnings
Order the properties to be copied onto the new object in an order that wouldn't throw warnings, eg. the "enabled-providers" property doesn't like to be set if the "application-id" and "contact-info" properties aren't set.
-rw-r--r--libgweather/gweather-weather.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/libgweather/gweather-weather.c b/libgweather/gweather-weather.c
index 897b684..d8301de 100644
--- a/libgweather/gweather-weather.c
+++ b/libgweather/gweather-weather.c
@@ -2437,9 +2437,10 @@ GWeatherInfo *
_gweather_info_new_clone (GWeatherInfo *original)
{
return g_object_new (GWEATHER_TYPE_INFO,
- "location", original->glocation,
- "enabled-providers", original->providers,
"application-id", original->application_id,
+ "contact-info", original->contact_info,
+ "enabled-providers", original->providers,
+ "location", original->glocation,
NULL);
}