code cleanup, v1.01 is finished