Drain the beans, collect the broth. Cut the onion into small cubes. Leave out the butter, fry the ham and onion in it. Stir in the flour, brown lightly.
Stir in a little milk and 3/4 of the broth and bring to the boil. Season to taste with pepper and nutmeg. Be careful with the salt, the ham cubes are already salty. If the sauce is too thick, add a little more broth. Too thin, then maybe help with a sauce thickener. At the end add the beans and heat them up in the sauce.
Boiled potatoes and meatballs go very well with this.