Added setInvitationAsDeleted and fixed potensial bug in RequestHandler

and ServerRequest