more checks for null input handling
Merge pull request #9 from VirusFree/pull_request

more checks for null input handling