[gnome-shell] extensionSystem: Don't spam the error log with OUT_OF_DATE errors
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] extensionSystem: Don't spam the error log with OUT_OF_DATE errors
- Date: Mon, 26 Nov 2012 20:12:08 +0000 (UTC)
commit ca73017100c6e94b937564fa60c1e42ab038c22b
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Mon Nov 26 14:21:03 2012 -0500
extensionSystem: Don't spam the error log with OUT_OF_DATE errors
Nobody cares
https://bugzilla.gnome.org/show_bug.cgi?id=689108
js/ui/extensionSystem.js | 26 ++++++++++----------------
1 files changed, 10 insertions(+), 16 deletions(-)
---
diff --git a/js/ui/extensionSystem.js b/js/ui/extensionSystem.js
index 4512fda..62775a3 100644
--- a/js/ui/extensionSystem.js
+++ b/js/ui/extensionSystem.js
@@ -126,11 +126,7 @@ function logExtensionError(uuid, error) {
let message = '' + error;
- if (error.state)
- extension.state = error.state;
- else
- extension.state = ExtensionState.ERROR;
-
+ extension.state = ExtensionState.ERROR;
if (!extension.errors)
extension.errors = [];
@@ -145,18 +141,16 @@ function loadExtension(extension) {
extension.state = ExtensionState.ERROR;
if (ExtensionUtils.isOutOfDate(extension)) {
- let error = new Error('extension is not compatible with current GNOME Shell and/or GJS version');
- error.state = ExtensionState.OUT_OF_DATE;
- throw error;
- }
-
- let enabled = enabledExtensions.indexOf(extension.uuid) != -1;
- if (enabled) {
- initExtension(extension.uuid);
- if (extension.state == ExtensionState.DISABLED)
- enableExtension(extension.uuid);
+ extension.state = ExtensionState.OUT_OF_DATE;
} else {
- extension.state = ExtensionState.INITIALIZED;
+ let enabled = enabledExtensions.indexOf(extension.uuid) != -1;
+ if (enabled) {
+ initExtension(extension.uuid);
+ if (extension.state == ExtensionState.DISABLED)
+ enableExtension(extension.uuid);
+ } else {
+ extension.state = ExtensionState.INITIALIZED;
+ }
}
_signals.emit('extension-state-changed', extension);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]