36 lines
1.2 KiB
Diff
36 lines
1.2 KiB
Diff
From e34033a9b9dca9bba9162f29e67d97e20843eff7 Mon Sep 17 00:00:00 2001
|
|
From: Ray Strode <rstrode@redhat.com>
|
|
Date: Wed, 16 Aug 2023 18:46:54 -0400
|
|
Subject: [PATCH 1/3] status/keyboard: Add a catch around reload call
|
|
|
|
Now that system input settings can get used in the user session
|
|
they're getting seen by the tests and the tests are complaining:
|
|
|
|
Unhandled promise rejection. To suppress this warning, add an
|
|
error handler to your promise chain with .catch() or a try-catch block
|
|
around your await expression.
|
|
|
|
This commit adds the catch it's asking for.
|
|
---
|
|
js/ui/status/keyboard.js | 4 +++-
|
|
1 file changed, 3 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/js/ui/status/keyboard.js b/js/ui/status/keyboard.js
|
|
index 8d98e16de9..7277c6d099 100644
|
|
--- a/js/ui/status/keyboard.js
|
|
+++ b/js/ui/status/keyboard.js
|
|
@@ -198,7 +198,9 @@ class InputSourceSystemSettings extends InputSourceSettings {
|
|
this._variants = '';
|
|
this._options = '';
|
|
|
|
- this._reload();
|
|
+ this._reload().catch(error => {
|
|
+ logError(error, 'Could not reload system input settings');
|
|
+ });
|
|
|
|
Gio.DBus.system.signal_subscribe(this._BUS_NAME,
|
|
this._BUS_PROPS_IFACE,
|
|
--
|
|
2.43.0
|
|
|