Move code into __setInvitationFlashMessages()