Removes old slave code