master cleanedup