You are lucky! Sometimes when I've eaten something off plan, I don't always end up re-awakening the cravings, and don't always experience a significant weight gain. I think this has to do with being kind of 'chintzy' about having a rare treat once in awhile.
See, what you did was have one or two items. You didn't go off plan for the whole day, whole week or whole vacation.
Just wanted to warn you though, that sometimes you can't always predict just what will trigger off those cravings again.
Anyway, glad to hear the consequences weren't too dire after all.
Meanwhile, I'm not sure what to suggest about your question though, if a treat every week or couple of weeks could be worked in. I'd be too scared to do that, but I do relax a wee bit when on vacation or once in awhile for a special occasion. For me, 'relaxing' a wee bit means I might just go right on ahead and have that baked sweet potato with my meal. I've also had a tiny bit of sherbet a couple of times in the last year, both on vacation.
In the past, I've found myself dealing with awful cravings after an off-plan meal, so I don't like to put myself through that. Nothing worse than struggling to get back on and battling cravings that had been tamed, for the most part.
I think your friend's chocolate treat is better than cake.
Even ice cream might be better than cake. Sure, they are definitely off plan, but for a lot of people, the combination of flour and sugar is a known trigger for cravings. Actually, anything sweet can do this, but combine flour and sugar, and the potential is worse for that kind of thing. Sherbet might be "better" (lesser of two evils) than ice cream. Not sure, since I don't really eat dairy anymore.
By the way, in The Primal Blueprint (Mark Sisson) - even chocolate is acceptable once in a rare while, referred to as a "sensible vice." Strange, but true. It's not built into the plan or anything, but really high quality dark chocolate once in awhile is not necessarily a diet destroyer.
Good luck working through these things. You're right to be thinking of the longer term view.
Oh, and one last tip - if you've had a 'treat' - plan on some extra exercise, as it'll help burn off the carbs. Lots of water is known to help too.