fixed nullpointer error
Merge pull request #20 from nnordhof/master

fixed nullpointer error