Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#2452 closed defect (fixed)

[cms] \n in a translatable string is being converted into an actual line break

Reported by: trev Assignee: kzar
Priority: P3 Milestone:
Module: Sitescripts Keywords:
Cc: kzar Blocked By:
Blocking: #2035 Platform: Unknown
Ready: yes Confidential: no
Tester: Verified working: yes
Review URL(s):

http://codereview.adblockplus.org/5172705124941824/

Description (last modified by kzar)

How to reproduce

Add the following code to a Markdown page:

{{string This is a line break <code><fix>\n</fix></code>}}

Observed behaviour

The following code is generated:

This is a line break <code>
</code>

Expected behaviour

The fixed string isn't interpreted:

This is a line break <code>\n</code>

Notes

Also see s40 in filters.html:
{{s40 Convert all line breaks to Unix style (replace <code><fix>\r</fix></code> by <code><fix>\n</fix></code> if present).}}

Change History (6)

comment:1 Changed 4 years ago by kzar

  • Owner set to kzar

comment:2 Changed 4 years ago by kzar

  • Description modified (diff)

comment:3 Changed 4 years ago by kzar

  • Review URL(s) modified (diff)
  • Status changed from new to reviewing

comment:4 Changed 4 years ago by kzar

  • Resolution set to fixed
  • Status changed from reviewing to closed

comment:6 Changed 4 years ago by Ross

  • Verified working set

Fixed.

Tested by:
Adding provided example to a CMS page and checking the output.

cms / r42

Note: See TracTickets for help on using tickets.