I went through a period where I told myself I didn’t need to take any extra sodium or anything for just a 42 hour fast. I had more leg cramps than the days I took a little. I don’t drink bouillon anymore, it’s just too salty for me (I was never someone to salt food heavily), but 1/4 teaspoon of Real Salt mixed with 1/4 tsp of Potassium chloride keeps the cramps away.
My calibration is that I’ve had them on non-fasting days, too. Always my right leg. Always the rightmost two or three toes.