exporter: give error on Describe of missing action

If someone calls org.gtk.Actions.Describe on a non-existent action then
return an exception instead of a trivial description (disabled, no
state, etc.).

https://bugzilla.gnome.org/show_bug.cgi?id=687185
This commit is contained in:
Ryan Lortie 2013-10-28 14:49:14 -07:00
parent e275b8bc6c
commit abb9a746f4

View File

@ -384,7 +384,7 @@ org_gtk_Actions_method_call (GDBusConnection *connection,
if (!g_action_group_has_action (exporter->action_group, name)) if (!g_action_group_has_action (exporter->action_group, name))
{ {
g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS,
"The named action does not exist."); "The named action ('%s') does not exist.", name);
return; return;
} }