Fixed Issue #1109

The uncaught exception was caused due to the change in the validator API. 

The package.json has been amended to lock the validator version to new api, since the call signature is different.

util.js has been edited to conform to new invocation methods.