Fixed nullPointerException on empty response

Applies to #116