Memory cleanup - rewrite of assertParam and partial update of Event + ajax changes