minor modifications to clean