corrects misbehavior of modal due to wrong pointer
adds all the necessary functionality for project and comment.