Add if statement before destructive command