Update upgrade.php

Added MISSING line at 284

Fixed code at line 288