A digestive slowdown can sometimes cause it to occur. This can then sometimes lead to GI stasis and a gut blockage occurring. But luckily it seems like your bun passed it ok. As long as he is eating, drinking, behaving normally, and his poops are looking normal now, I would think it was just a one off thing, which does sometimes happen.