Implement usernames

 - fix naming of vars in nested closures
 - refactor tests