- 
                Notifications
    You must be signed in to change notification settings 
- Fork 146
machina.off
        Jim Cowart edited this page Feb 2, 2015 
        ·
        2 revisions
      
    description: unsubscribes an event listener from being notified of the specified event.
- 
eventName- string argument name from which you are unsubscribing (note: the only event currently emitted by the machina namespace is thenewfsmevent).
- 
callback- reference to the function that was used to subscribe
Example Usage:
// to subscribe
var callback = function(fsm) {
    // does something with the fsm
};
var listener = machina.on("newfsm", callback);
// to unsubscribe:
machina.off("newfsm", callback);
// OR
listener.off();