cleaned up with maps and copy