Various minor fixes to small things

noticed while trying to run the lottery