The script depends on a title being present in title attribute. So
skip links without title attributes (which were getting empty
attributes due to the implementation of removeTooltips) and bail on
trying to open a preview for links without a title.
Bug: 67728
Change-Id: I4cc744bea10af34741681f11e03d77b3d53e3a3b
removeBracketsFromText doesn't count it tracks nesting level, and
brackets are [] not (). Minor detail.
Change-Id: I8f42b1ccae5233d7b6062bb311eced6ef3085d4a
In combination with other gadgets the error
TypeError: re.query is undefined
can occur because the request contains titles:'' and the response is [].
Change-Id: I46d02e7c48a55cd9af20fd7ef729b4d26f69a8c0
Casees:
1) Hello (and welcome)
2) Hello )and welcome(
3) (Hello (and) welcome)
The current RegExp only takes care of (1). The new code should
take care of all the cases.
Bug: 65138
Change-Id: I39f38beed0cf612067d6fc61b18295d1d38fcc22
These links were not ignored due to a typo. This also threw an error,
because these links produced query.interwiki and not in query.pages.
Change-Id: I3b5c5b900209323e3e72b41e3b02e90f1f53b4eb