SoupSession: fix a bug with the add-feature-by-type property
authorDan Winship <danw@gnome.org>
Thu, 7 Feb 2013 19:14:47 +0000 (14:14 -0500)
committerDan Winship <danw@gnome.org>
Thu, 7 Feb 2013 21:20:22 +0000 (16:20 -0500)
The add-feature-by-type and remove-feature-by-type properties were
only accepting SoupSessionFeature types, so you couldn't use it for
things like request types, auth types, etc.

libsoup/soup-session.c

index b2f7614..c50faa2 100644 (file)
@@ -3429,7 +3429,7 @@ soup_session_class_init (SoupSessionClass *session_class)
                g_param_spec_gtype (SOUP_SESSION_ADD_FEATURE_BY_TYPE,
                                    "Add Feature By Type",
                                    "Add a feature object of the given type to the session",
-                                   SOUP_TYPE_SESSION_FEATURE,
+                                   G_TYPE_OBJECT,
                                    G_PARAM_READWRITE));
        /**
         * SoupSession:remove-feature-by-type: (skip)
@@ -3452,7 +3452,7 @@ soup_session_class_init (SoupSessionClass *session_class)
                g_param_spec_gtype (SOUP_SESSION_REMOVE_FEATURE_BY_TYPE,
                                    "Remove Feature By Type",
                                    "Remove features of the given type from the session",
-                                   SOUP_TYPE_SESSION_FEATURE,
+                                   G_TYPE_OBJECT,
                                    G_PARAM_READWRITE));
        /**
         * SoupSession:http-aliases: