When removing the old search box code, we left some old JS in the code:
- We forgot to clean up this: https://github.com/wikimedia/wikimedia-portals/blob/master/dev/wikipedia.org/assets/js/wm-portal.js#L191-L250
- And some of this https://github.com/wikimedia/wikimedia-portals/blob/master/dev/wikipedia.org/assets/js/wm-portal.js#L191-L250 should also be cleaned up, and moved to the new code.
Thankfully this doesn't seem to create any bug or conflict !
#EDIT#
I'll also add to this ticket comments mentioned [[ https://gerrit.wikimedia.org/r/#/c/282710/ | here ]]:
- document the functionality of `controller.js` to note that even though some parts aren't used in production, they might be useful in the future.
- Place all the JS code back at the bottom of the file
and
- rename references to the A/B tests in the code, such as `pab2.js'