Fixed undefined variable error

Sometimes nodejs crash with `Pa undefined`
Merge pull request #21 from alexgus/patch-2

Fixed undefined variable error