Removing bad code from example