mirror of
https://github.com/atom/atom.git
synced 2026-02-18 02:21:43 -05:00
Pass selector first to CommandRegistry::add
This commit is contained in:
@@ -9,7 +9,7 @@ class CommandRegistry
|
||||
constructor: (@rootNode) ->
|
||||
@listenersByCommandName = {}
|
||||
|
||||
add: (commandName, selector, callback) ->
|
||||
add: (selector, commandName, callback) ->
|
||||
unless @listenersByCommandName[commandName]?
|
||||
@rootNode.addEventListener(commandName, @dispatchCommand, true)
|
||||
@listenersByCommandName[commandName] = []
|
||||
|
||||
Reference in New Issue
Block a user