Prevent error if data is undefined when  is run.
Merge pull request #36 from NateRedding/master

Fixes issue #33