         self.state = state
         self.mutations = mutations
         
-        disposableScope += dispatcher.subscribe(store: self, executer: executer)
-        disposableScope += Dispatcher<State>.shared.subscribe(store: self, executer: executer)
+        @inline(__always)
+        func subscribe(to dispatcher: Dispatcher<State>) {
+            let key = dispatcher.subscribe(store: self, executer: executer)
+            subscribedDispatchers.append((key: key, dispatcher: dispatcher))
+        }
+        
+        subscribe(to: dispatcher)
+        subscribe(to: Dispatcher<State>.shared)
+    }
+    
+    deinit {
+        for (key, dispatcher) in subscribedDispatchers {
+            dispatcher.unsubscribe(for: key)
+        }
     }
     
     fileprivate func dispatch(action: State.Action) {

    private let state: State
    private let mutations: State.Mutations
    private let dispatcher = Dispatcher<State>()
    private let disposableScope = Dispatcher<State>.Disposable.Scope()
    
    public static var actions: Actions<State> {
        return .init(dispatcher: Dispatcher<State>.shared)

        }
    }
    
    func subscribe(store: Store<State>, executer: Executer) -> Key {
        return buffer.modify { buffer in
            let key = buffer.nextKey
            buffer.nextKey = key.next
            
            let observer: (State.Action) -> Void = { [weak store] action in
                executer.execute { store?.dispatch(action: action) }
            }
            
            buffer.subscriptions.append((key: key, observer: observer))
            return key
        }
    }
    
    func unsubscribe(for key: Key) {
        buffer.modify { buffer in
            for index in buffer.subscriptions.startIndex..<buffer.subscriptions.endIndex where buffer.subscriptions[index].key == key {
                buffer.subscriptions.remove(at: index)
