T_Else Error while upgrading to the latest version