Merge pull request #15 from claudiojs/master

Update main.js - thanks claudio
Support for functions added to prototype
Merge pull request #16 from robso86/master

Support for functions added to prototype