bug null exception

bug null exception
Merge pull request #150 from salvadorcortes/master

bug null exception