shellDBus: Actually make ScreenTransitionAsync async

We called such function async but we didn't awaited for the
checkInvocation result in the proper way.

So on failure the shell would report an unhandled promise rejection.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2258>
This commit is contained in:
Marco Trevisan (Treviño) 2022-03-28 15:25:41 +02:00
parent ef2136877f
commit 8ba7f0f4a9

View File

@ -253,9 +253,9 @@ var GnomeShell = class {
invocation.return_value(GLib.Variant.new('(b)', [ungrabSucceeded])); invocation.return_value(GLib.Variant.new('(b)', [ungrabSucceeded]));
} }
ScreenTransitionAsync(params, invocation) { async ScreenTransitionAsync(params, invocation) {
try { try {
this._senderChecker.checkInvocation(invocation); await this._senderChecker.checkInvocation(invocation);
} catch (e) { } catch (e) {
invocation.return_gerror(e); invocation.return_gerror(e);
return; return;