handle case when query returns None
handle case when query returns None

svanoort/pyresttest,netjunki/pyresttest,satish-suradkar/pyresttest,netjunki/pyresttest,svanoort/pyresttest,satish-suradkar/pyresttest