Put the emit of the signal new/editProject at the end of the method