⚓ T90476 Trying to re-use a reference replacing itself crashes; should instead be a no-op
- ️Mon Feb 23 2015
Trying to re-use a reference replacing itself crashes; should instead be a no-op
Closed, ResolvedPublic1 Estimated Story Points
Trying to re-use a reference replacing itself crashes; should instead be a no-op
Closed, ResolvedPublic1 Estimated Story Points
Steps to reproduce:
- Open a page with VE
- Insert a Basic Reference
3.Reopen the reference dialog again.
4.Now delete the text from the textfield , this will enable "Use existing reference" button in the dialog
5.Now go ahead and click on that button
6.Select this same reference, which is showing up in the list
Observed Result:
The following error appears in the console:
Uncaught TypeError: Cannot read property 'length' of undefined
Expected Result:
Probably we should not show the same reference in the Use existing reference list while accessing it from that reference dialog ?
Event Timeline
Ryasmeen raised the priority of this task from to Needs Triage.
Or reusing the same reference can cause us to just discard any of your changes and close the reference dialog, since you're saying you want to re-use the existing content? @Jdforrester-WMF, what do you think?
Jdforrester-WMF renamed this task from TypeError "Cannot read property 'length' of undefined" appears while trying to select the same reference from Use Existing Reference dialog to Trying to re-use a reference replacing itself crashes; should instead be a no-op.Sep 15 2015, 6:57 PM
(It turns out this bug seems much easier to fix than when I thought about it two months ago. And I'm pretty sure it's my code that broke this, sorry :()
Content licensed under Creative Commons Attribution-ShareAlike (CC BY-SA) 4.0 unless otherwise noted; code licensed under GNU General Public License (GPL) 2.0 or later and other open source licenses. By using this site, you agree to the Terms of Use, Privacy Policy, and Code of Conduct. · Wikimedia Foundation · Privacy Policy · Code of Conduct · Terms of Use · Disclaimer · CC-BY-SA · GPL · Credits