first-run bug fixes