Template talk:Junction
Add topic| Template:Junction is indefinitely protected from editing as it is a heavily used or highly visible template. Substantial changes should first be proposed and discussed here on this page. If the proposal is uncontroversial or has been discussed and is supported by consensus, editors may use {{edit template-protected}} to notify a template editor to make the requested edit. Usually, any contributor may edit the template's documentation to add usage notes or categories.
Any contributor may edit the template's sandbox. Functionality of the template can be checked using test cases. |
| This is the talk page for discussing Junction and anything related to its purposes and tasks. |
|
| This template does not require a rating on Wikipedia's content assessment scale. It is of interest to the following WikiProjects: | ||||||||
| ||||||||
|
Edit request 23 June 2026
[edit]This edit request to Module:Jct has been answered. Set the |answered= parameter to no to reactivate your request. |
Description of suggested change: Remove the vestigial variables statenameModuleName (only initialized and completely unused), missingShields (only initialized to empty and read), allMissingShields (only initialized to empty and read), shieldExistsCache (only initialized to empty and completely unused).
Diff: Special:Diff/1360722589. Note this is not the same starting-point as the published version (I did not want to undo Hike395's change), but the changes are straightforward to port.
Commentary: The existence check is currently fully handled by Module:Road data/parser. An existence check (that does not detect the fallback) should be possible by checking for a nil return on a filename call, but given that the current situation works, there's no point in doing that. Also, there are plenty of nil-checks on the parser return values already and messing with them could break things.
Artoria2e5 🌉 05:25, 23 June 2026 (UTC)
- Just cleaned up some other unused aspects myself. Looking at it closer, there seems to be quite a few function parameters that just don't get used (e.g.
shieldSpecuses neithermainShieldnorshieldListandrenderdoesn't useshowLink), as well as one of the functions (render) referencing a global like a local (landscape and "x" or ""- landscape isn't defined anywhere), which makes me somewhat worried these are bugs rather than missed cleanup. Are there any features or anything that's gone missing/broke at any point, or is it safe to assume it's just leftover behaviour and can be cleaned up? Aidan9382 (talk) 22:04, 26 July 2026 (UTC)