Permalink
Browse files

Merge pull request #81 from ryan-nauman/master

simple unbind global leak fix
  • Loading branch information...
2 parents 4972b92 + 1d01ca6 commit ddcb72eceb033dbdd83e5b45deabca15ec3b37bc @madrobby committed Apr 27, 2013
Showing with 3 additions and 3 deletions.
  1. +3 −3 keymaster.js
View
@@ -136,15 +136,15 @@
// parse and assign shortcut
function assignKey(key, scope, method){
- var keys, mods, i, mi;
+ var keys, mods;
keys = getKeys(key);
if (method === undefined) {
method = scope;
scope = 'all';
}
// for each shortcut
- for (i = 0; i < keys.length; i++) {
+ for (var i = 0; i < keys.length; i++) {
// set modifier keys if any
mods = [];
key = keys[i].split('+');
@@ -242,7 +242,7 @@
// abstract mods logic for assign and unassign
function getMods(key) {
var mods = key.slice(0, key.length - 1);
- for (mi = 0; mi < mods.length; mi++)
+ for (var mi = 0; mi < mods.length; mi++)
mods[mi] = _MODIFIERS[mods[mi]];
return mods;
}

0 comments on commit ddcb72e

Please sign in to comment.