fixed gist code to work

had to wrap map() inside list()