The Rambam explains that if, on Shabbat, a person gathered white figs while intending to gather black figs, he is exempt. But the Rambam also says that if he intended to light one candle and mistakenly lit another, he is liable. Why do two seemingly identical scenarios not have the same law?