spooky - looks like there is code missing.
in addition there is still the old checkUpgrade() code in lib/private/app.php