"Going home on a whim" means coming in high spirits.
People often say, "I came on an impulse and came home with a full load", that is, I came with interest and then came back without losing my expectation.
Or "I came on impulse and came back disappointed", that is to say, I heard that it was fun and went happily, only to find that it was not fun at all and I was disappointed.
I hope I can help you!