fixing NPE
Merge pull request #5 from wso2-dev/master

fixing NPE