[BISERVER-8405, BISERVER-8420] fixed null pointer issues