update of all code for new edition