Update index.js

Don't wrap functions, only generators
Merge pull request #2 from litek/patch-1

Only wrap generators