Add back in automatic db upgrading, thanks Danny for spotting!