@@ -1343,15 +1343,12 @@ void ScriptMgr::Initialize()
13431343 // Remove the used scripts from the given container.
13441344 sScriptRegistryCompositum ->RemoveUsedScriptsFromContainer (unusedScriptNames);
13451345
1346- for (std::string const & scriptName : unusedScriptNames)
1347- {
1348- // Avoid complaining about empty script names since the
1349- // script name container contains a placeholder as the 0 element.
1350- if (scriptName.empty ())
1351- continue ;
1346+ // Avoid complaining about empty script names since the
1347+ // script name container contains a placeholder as the 0 element.
1348+ unusedScriptNames.erase (" " );
13521349
1350+ for (std::string const & scriptName : unusedScriptNames)
13531351 TC_LOG_ERROR (" sql.sql" , " Script '{}' is referenced by the database, but does not exist in the core!" , scriptName);
1354- }
13551352
13561353 TC_LOG_INFO (" server.loading" , " >> Loaded {} C++ scripts in {} ms" ,
13571354 GetScriptCount (), GetMSTimeDiffToNow (oldMSTime));
@@ -2595,7 +2592,7 @@ BattlegroundMapScript::BattlegroundMapScript(char const* name, uint32 mapId) noe
25952592 if (!GetEntry ())
25962593 TC_LOG_ERROR (" scripts" , " Invalid BattlegroundMapScript for {}; no such map ID." , mapId);
25972594
2598- if (GetEntry () && !GetEntry ()->IsBattleground ())
2595+ if (GetEntry () && !GetEntry ()->IsBattlegroundOrArena ())
25992596 TC_LOG_ERROR (" scripts" , " BattlegroundMapScript for map {} is invalid." , mapId);
26002597
26012598 ScriptRegistry<BattlegroundMapScript>::Instance ()->AddScript (this );
0 commit comments