From 03964ff568275efb26740220db09ef357967fe94 Mon Sep 17 00:00:00 2001 From: Kevin Sawicki Date: Mon, 14 Oct 2013 17:23:53 -0700 Subject: [PATCH] Unsubscribe from buffer when destroyed --- src/git.coffee | 1 + 1 file changed, 1 insertion(+) diff --git a/src/git.coffee b/src/git.coffee index 20f9d3745..55519741a 100644 --- a/src/git.coffee +++ b/src/git.coffee @@ -80,6 +80,7 @@ class Git @getPathStatus(path) @subscribe buffer, 'saved', bufferStatusHandler @subscribe buffer, 'reloaded', bufferStatusHandler + @subscribe buffer, 'destroyed', => @unsubscribe(buffer) # Public: Destroy this `Git` object. This destroys any tasks and # subscriptions and releases the underlying libgit2 repository handle.