Bug 22243: Fix unescaped apostrophe in Z target

This patch escapes apostrophes in the z39.50 target name prior to them
being embedded in the template.

To test:

- Create a z39.50 target containing an apostrophe in the title
- Note that the Advanced Cataloguer editor does not load
- Apply the patch
- TEST: Note that the Advanced Cataloguer editor does load

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Andrew Isherwood 2019-01-31 09:40:08 +00:00 committed by Jonathan Druart
parent 28423fa756
commit 7ffa71fbd1
1 changed files with 1 additions and 1 deletions

View File

@ -51,7 +51,7 @@ require( [ 'koha-backend', 'search', 'macros', 'marc-editor', 'marc-record', 'pr
[%- FOREACH server = z3950_servers -%]
{
server_id: [% server.id | html %],
name: '[% server.servername | html %]',
name: '[% server.servername | html_entity %]',
recordtype: '[% server.recordtype | html %]',
checked: [% server.checked ? 'true' : 'false' | html %],
},