Page MenuHomePhabricator

VisualEditor: removeHtmlAttributes throws an exception when copying complex templates
Closed, ResolvedPublic


Steps to reproduce:

1.Open the editor.
2.Add a template
3.Save the page
4.Reopen the editor
5.Copy the template

Observed Result:

It gives an error:Uncaught TypeError: Cannot convert null to object .However, it does get pasted correctly onto other VE.

Version: unspecified
Severity: normal



Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 2:18 AM
bzimport set Reference to bz58421.

Test Environment: production-
Browser: Chrome Version 26.0.1410.65 & FF 25
OS: MAC OS X 10. 8. 5

Created attachment 14077


Can you reproduce on beta labs?

Change 101148 had a related patch set uploaded by Esanders:
Check values property exists before remove attribute

For betalabs, I could reproduce for only templates which has parameters with values

Change 101148 merged by jenkins-bot:
Check values property exists before removing attribute

Verified the fix in test2 with MediaWiki 1.23wmf8 on page: