daviferreira/medium-editor — pull request #153 by 2rp (2014-02-26 12:53:01+00:00)
Title: Deactivated Medium Editor doesn't stop listening on paste events

When deactivating the editor I found that it doesn't stop listening on the paste event. So if I initialize an editor, deactivate it, intialize another editor, paste in some content, it will execute the the pasteWrapper handler twice, inserting the content two times.

To fix it, I keep a reference to the pasteWrapper (on this), so we can remove the event listener on 'paste' when deactivating the editor.