Page MenuHomePhabricator

TypeError: cur is null when pasting HTML tags on Flow topics
Open, Needs TriagePublic

Description

  1. Copy the string <blockquote>
  2. Start a new topic at https://www.mediawiki.org/wiki/Talk:Structured_Discussions
  3. Paste it twice, so that the content is <blockquote><blockquote>

There will be an error in the console:

TypeError: cur is null[Learn More] load.php:69:929

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

I don't have that error on Chromium, either logged-in or logged-out.

Have you pasted it in the visual or wikitext editor? do you have that error using safemode?

I'm testing it using Firefox, with source editing. By safemode do you mean debug=1? It also happens, and the error comes from these lines:

			// Support: IE <=9
			// Black-hole SVG <use> instance trees (trac-13180)
			cur.nodeType &&

from https://www.mediawiki.org/w/load.php?debug=true&lang=en&modules=jquery%7Cmediawiki.base%7Cmediawiki.legacy.wikibits&only=scripts&skin=vector&version=19lyfvl

TypeError: cur is null[Learn More] load.php:5237:1
handlers
https://www.mediawiki.org/w/load.php:5237:1
dispatch
https://www.mediawiki.org/w/load.php:5187:18
add/elemData.handle
https://www.mediawiki.org/w/load.php:5014:6

On Firefox 61, with ?safemode=1, pasting <blockquote> twice does not trigger the error, but pasting <div> twice does. I was not able to reproduce the error using Chromium 67.

On FF61 I do not see any Console errors if I start a topic with <blockquote><blockquote> or`<div><div>. Since <blockquote> does not trigger the Console error with ?safemode=1` that means that you have some custom scripts.

My steps <div><div> :

  1. In FF61, on https://www.mediawiki.org/wiki/User_talk:Etonkovidova, I start a new topic.
  2. Paste div twice - I did it in the title and in the text area (in wikitext mode) - no Console errors were displayed to me.