Fixed incorrect folder removal.