Some upgrades and fixes.