This may just be a bug specifically triggered by my own code, but it doesn't smell like it.
Steps to replicate the issue (include links if applicable):
- Fire up VE with edit check enabled
- Create an external hyperlink in a document and publish it
- Edit again. Make some changes in the document so that you've got a couple of modified ranges
- Add a breakpoint somewhere where getModifiedRanges() executes in a check.
- Edit your hyperlink – in my case I changed an https to an http
What happens?:
- getModifiedRanges() starts returning [] instead of
What should have happened instead?:
getModifiedRanges() should continue to return the ranges it returned before, plus a new range for the edited hyperlink
Software version (on Special:Version page; skip for WMF-hosted wikis like Wikipedia):
Other information (browser name/version, screenshots, etc.): https://gerrit.wikimedia.org/r/c/mediawiki/extensions/VisualEditor/+/1108462/