[gnome-shell/wip/rstrode/login-screen-extensions: 57/134] extensionDownloader: Remove pending updates with extension
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/rstrode/login-screen-extensions: 57/134] extensionDownloader: Remove pending updates with extension
- Date: Thu, 26 Aug 2021 19:30:59 +0000 (UTC)
commit 62b37fecf335dcaa5677caeb576325a2a5bc8604
Author: Florian Müllner <fmuellner gnome org>
Date: Mon Mar 9 16:49:34 2020 +0100
extensionDownloader: Remove pending updates with extension
When an extension is uninstalled, there is no point in keeping
a pending update: If the update didn't fail (which it currently
does), we would end up sneakily reinstalling the extension.
https://gitlab.gnome.org/GNOME/gnome-shell/issues/2343
js/ui/extensionDownloader.js | 9 +++++++++
1 file changed, 9 insertions(+)
---
diff --git a/js/ui/extensionDownloader.js b/js/ui/extensionDownloader.js
index f957c6c623..0bd77e1256 100644
--- a/js/ui/extensionDownloader.js
+++ b/js/ui/extensionDownloader.js
@@ -55,6 +55,15 @@ function uninstallExtension(uuid) {
return false;
FileUtils.recursivelyDeleteDir(extension.dir, true);
+
+ try {
+ const updatesDir = Gio.File.new_for_path(GLib.build_filenamev(
+ [global.userdatadir, 'extension-updates', extension.uuid]));
+ FileUtils.recursivelyDeleteDir(updatesDir, true);
+ } catch (e) {
+ // not an error
+ }
+
return true;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]