Fixes #31

currData most not be null or undefined
Merge pull request #32 from raphaelcruzeiro/master

Fixes #31