fixed null exceptions in result page of research, minor code cleanup