Permalink
Browse files

Add global subscriptionCount method to Repository to ensure no subscr…

…iption leaks in specs
  • Loading branch information...
nathansobo committed Sep 15, 2012
1 parent 721d8f2 commit c20641b6375e7da21315eddcb6679561566dd515
Showing with 6 additions and 0 deletions.
  1. +6 −0 lib/assets/javascripts/monarch/repository.coffee
@@ -66,3 +66,9 @@ Monarch.Repository =
@pauseCount = 0
delete @deferredUpdates
table.clear() for name, table of @tables
+
+ subscriptionCount: ->
+ count = 0
+ for name, table of @tables
+ count += table.subscriptionCount()
+ count

0 comments on commit c20641b

Please sign in to comment.