connect();$db->query('SELECT 1')->fetchColumn(); if(!(new RosterService())->ready())throw new RuntimeException('Required schema is missing.'); foreach(['user_email_verified_at'] as $column){$columns=$db->query('SHOW COLUMNS FROM users')->fetchAll(PDO::FETCH_COLUMN);if(!in_array($column,$columns,true))throw new RuntimeException('Account schema is missing.');} echo "Database and required application schema are available.\n"; }catch(Throwable $e){fwrite(STDERR,"Health check failed. Review the protected server logs.\n");error_log((string)$e);exit(1);}