refactor: remove direct calls to mw.ext.teamtemplate#6624
Merged
Conversation
hjpalpha
reviewed
Oct 4, 2025
95bdcad to
06dba9d
Compare
5191630 to
34ef3d9
Compare
Collaborator
|
Status? |
Collaborator
Author
|
iirc technically finished but remains untested |
6f391b3 to
dd2d809
Compare
hjpalpha
approved these changes
Mar 6, 2026
Eetwalt
reviewed
Apr 15, 2026
Collaborator
|
merge conflict |
4782b4a to
33e5e6b
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
This PR addresses issue #6496 by refactoring Lua modules to avoid direct calls to mw.ext.TeamTemplate APIs, routing team lookups/display through Module:TeamTemplate and Module:OpponentDisplay/Custom instead.
Changes:
- Replaced
mw.ext.TeamTemplate.*calls (e.g.,teampage,raw,teamexists,team,teamicon) withTeamTemplate.*wrappers andOpponentDisplay.InlineTeamContainer. - Adjusted infobox “favorite teams” rendering to return/render VNode arrays instead of concatenated wikitext strings.
- Updated
Module:TeamTemplatehelpers (e.g.,getPageNamesignature,getRawOrNilempty-input handling) to support the new call patterns.
Reviewed changes
Copilot reviewed 51 out of 51 changed files in this pull request and generated 18 comments.
Show a summary per file
| File | Description |
|---|---|
| lua/wikis/zula/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/wildrift/Infobox/Person/Player/Custom.lua | Use TeamTemplate.getPageName for LPDB team2. |
| lua/wikis/trackmania/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/squadrons/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/splatoon/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/sideswipe/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/runeterra/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/rocketleague/Ratings/Display/List.lua | Replace team display with OpponentDisplay.InlineTeamContainer. |
| lua/wikis/rocketleague/Ratings/Display.lua | Use TeamTemplate existence/raw access for short names. |
| lua/wikis/rocketleague/Infobox/Person/Player/Custom.lua | Use TeamTemplate.exists for invalid-team categorization. |
| lua/wikis/rainbowsix/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/pubgmobile/Infobox/Person/Player/Custom.lua | Use TeamTemplate.getPageName for LPDB team2. |
| lua/wikis/pubg/Infobox/Person/Player/Custom.lua | Use TeamTemplate.getPageName for LPDB team2. |
| lua/wikis/overwatch/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/overwatch/Infobox/Person/User/Custom.lua | Align favorite-team widget children shape with new return type. |
| lua/wikis/overwatch/Infobox/Person/Player/Custom.lua | Use TeamTemplate.getPageName for LPDB team2. |
| lua/wikis/leagueoflegends/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/halo/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/freefire/Infobox/Person/Player/Custom.lua | Use TeamTemplate.getPageName (with fallback) for LPDB team2. |
| lua/wikis/formula1/PortalPlayers/Custom.lua | Use TeamTemplate.exists for team widget display gating. |
| lua/wikis/esports/Widget/EwcTeamsOverview.lua | Replace team wikitext with OpponentDisplay.InlineTeamContainer. |
| lua/wikis/easportsfc/PortalPlayers/Custom.lua | Use TeamTemplate.exists for team widget display gating. |
| lua/wikis/dota2/Infobox/Person/User/Custom.lua | Align favorite-team widget children shape with new return type. |
| lua/wikis/crossfire/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/criticalops/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/counterstrike/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/commons/TransferRow.lua | Use TeamTemplate.getRawOrNil for transfer team lookup by date. |
| lua/wikis/commons/TransferList.lua | Use TeamTemplate.exists/noTeamMessage/queryHistoricalNames for team sets. |
| lua/wikis/commons/TeamTemplate.lua | Adjust TeamTemplate helpers used by refactor (page name lookup + empty guard). |
| lua/wikis/commons/TeamLogoGallery.lua | Use TeamTemplate.exists/getRaw and centralized missing-team messaging. |
| lua/wikis/commons/Standings/Storage.lua | Use TeamTemplate.exists/getRaw for standings team resolution. |
| lua/wikis/commons/Service/Team.lua | Use TeamTemplate.getRawOrNil instead of extension checks. |
| lua/wikis/commons/SeriesMedalStats/ParticipantTeam.lua | Use OpponentDisplay and TeamTemplate.getRawOrNil for team resolution/display. |
| lua/wikis/commons/SeriesMedalStats/Participant.lua | Use TeamTemplate.getRawOrNil for team resolution. |
| lua/wikis/commons/Ratings.lua | Refactor team transfer logic away from mw.ext.TeamTemplate. |
| lua/wikis/commons/PrizePool/Placement.lua | Use TeamTemplate.getRawOrNil for logo fields. |
| lua/wikis/commons/PrizePool/Award/Placement.lua | Use TeamTemplate.getRawOrNil for participant/team fields. |
| lua/wikis/commons/PortalPlayers.lua | Use TeamTemplate.exists for team widget display gating. |
| lua/wikis/commons/PlayerIntroduction.lua | Use TeamTemplate.getRawOrNil for team display by date. |
| lua/wikis/commons/Infobox/Person/User/Custom.lua | Align favorite-team widget children shape with new return type. |
| lua/wikis/commons/Infobox/Person/User.lua | Return favorite teams as VNode list via OpponentDisplay. |
| lua/wikis/commons/Infobox/Person.lua | Use TeamTemplate + OpponentDisplay for team icons/name header rendering. |
| lua/wikis/commons/AutomaticPointsTable/MinifiedDisplay.lua | Replace team wikitext with OpponentDisplay.InlineTeamContainer. |
| lua/wikis/commons/AutomaticPointsTable/Display.lua | Replace team wikitext with OpponentDisplay.InlineTeamContainer. |
| lua/wikis/callofduty/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/brawlstars/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/battalion/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/arenafps/Match/Legacy.lua | Switch match opponent team resolution off mw.ext.TeamTemplate. |
| lua/wikis/apexlegends/Infobox/Person/Player/Custom.lua | Use TeamTemplate.getPageName for LPDB team2. |
| lua/wikis/ageofempires/MatchGroup/Input/Custom.lua | Use TeamTemplate.getRawOrNil for team page lookup. |
| lua/wikis/ageofempires/Match/Legacy.lua | Switch team page extraction off mw.ext.TeamTemplate.raw. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Rathoz
approved these changes
Jul 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Resolves #6496
How did you test this change?
preview with dev