Bug Tracker

Opened 6 years ago

Closed 6 years ago

#13402 closed bug (notabug)

Crashing when beginning with newlines

Reported by: hauke@… Owned by: hauke@…
Priority: undecided Milestone: None
Component: unfiled Version: 1.9.1
Keywords: Cc:
Blocked by: Blocking:

Description

Today we switched from jQuery 1.8.3 to 1.9.1 and the following occured:

When a string containing HTML beginning with one or more newlines is passed to jQuery to get an jQuery object it fails with a syntax error.

I created two gists to reproduce the problem.

Working with 1.8.3: https://gist.github.com/Partyschaum/4723647

Not working in 1.9.x (I tested 1.9.0 and 1.9.1): https://gist.github.com/Partyschaum/4723669

Regards, Hauke

Change History (3)

comment:1 Changed 6 years ago by dmethvin

Owner: set to hauke@…
Status: newpending

What did the jQuery Migrate plugin say?

comment:2 in reply to:  1 Changed 6 years ago by hauke@…

Status: pendingnew

Replying to dmethvin:

What did the jQuery Migrate plugin say?

JQMIGRATE: $(html) HTML strings must start with '<' character

Ok, that exactly was my "fix" until now. Then it's no bug. Instead I've to cleanup my HTML strings before putting them into jQuery.

Thx!

This ticket could be closed.

Greetings from Hamburg!

comment:3 Changed 6 years ago by dmethvin

Resolution: notabug
Status: newclosed
Note: See TracTickets for help on using tickets.