Fixing 'key' out of scope, @gilly3
Merge pull request #13 from pedroassis/master

Fixing 'key' out of scope, @gilly3