cleanup & fixing to new edition