Steps to replicate the issue (include links if applicable):
- Go to https://commtech.toolforge.org/index.php?title=Community_Wishlist/Wishes&action=edit
- Change the wikitext to be just {{#CommunityRequests:wish-index}}
- Preview
What happens?:
Error: Call to a member function toBcp47Code() on null
What should have happened instead?:
Sensible defaults should have been used for the lang, sort, dir and limit parameters.
Other information
Even if a value is supplied, say for lang, it doesn't seem to take effect. It's an issue with the Vue app or init script, I believe.
Derived Requirement
Ensure that the #CommunityRequests:wish-index parser function initializes the Vue app without runtime errors by applying sensible default values for lang, sort, dir, and limit when parameters are not provided, and by correctly respecting any explicitly provided parameter values.
Test Steps
Test Case 1: Render wish index with no parameters
- Go to https://commtech.toolforge.org/index.php?title=Community_Wishlist/Wishes&action=edit
- Replace the wikitext with {{#CommunityRequests:wish-index}}
- Click Show preview
- ✅❓❌⬜ AC1: The Vue app should render using default lang, sort, dir, and limit values without showing a PHP runtime error
Test Case 2: Render wish index with explicit lang parameter
- Go to https://commtech.toolforge.org/index.php?title=Community_Wishlist/Wishes&action=edit
- Replace the wikitext with {{#CommunityRequests:wish-index:lang=en}}
- Click Show preview
- ✅❓❌⬜ AC2: The Vue app should render without errors and display content in the specified language
Test Case 3: Render wish index with all parameters provided
- Go to https://commtech.toolforge.org/index.php?title=Community_Wishlist/Wishes&action=edit
- Replace the wikitext with {{#CommunityRequests:wish-index:lang=en|sort=upvotes|dir=desc|limit=10}}
- Click Show preview
- ✅❓❌⬜ AC3: The Vue app should respect the provided parameters and display the list sorted and limited as specified
Test Case 4: Validate Vue initialization without errors
- Repeat Test Case 1 or 2
- Open the browser developer console
- ✅❓❌⬜ AC4: There should be no JavaScript or Vue runtime error related to missing or null parameter values
Test Case 5: Graceful fallback when parameters are missing
- Repeat Test Case 1
- ✅❓❌⬜ AC5: The app should gracefully fallback to defaults without crashing or triggering toBcp47Code() on null
QA Results - commtech.toolforge
| AC | Status | Details |
|---|---|---|
| 1 | ✅ | T401270#11080150 |
| 2 | ✅ | T401270#11099114 |
| 3 | ✅ | T401270#11140827 |
| 4 | ✅ | T401270#11080150 |
| 5 | ✅ | T401270#11099114 |


















