add if to borrowed ptr tutorial

Just adds a forgotten if.