handle null responses from servers
Merge pull request #1 from HBOCodeLabs/nullref

handle null responses from servers