[gnome-sound-recorder] no handler attached to id fix



commit 670a7ba0ce744fdbfeba04ed74a9919a95f1b9f6
Author: Kavan Mevada <kavanmevada gmail com>
Date:   Fri Aug 14 23:06:26 2020 +0530

    no handler attached to id fix

 src/window.js | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
---
diff --git a/src/window.js b/src/window.js
index 9707aba..154837b 100644
--- a/src/window.js
+++ b/src/window.js
@@ -148,7 +148,10 @@ var Window = GObject.registerClass({
         this.deleteSignalId = GLib.timeout_add_seconds(GLib.PRIORITY_DEFAULT, 3, () => {
             callback();
             this._notificationRevealer.reveal_child = false;
-            this._notificationUndoBtn.disconnect(this.cancelSignalId);
+            if (this.cancelSignalId && this.cancelSignalId > 0) {
+                this._notificationUndoBtn.disconnect(this.cancelSignalId);
+                this.cancelSignalId = -1;
+            }
         });
 
         this.cancelSignalId = this._notificationUndoBtn.connect('clicked', _ => {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]