This commit is contained in:
Kovid Goyal 2023-01-19 08:43:43 +05:30
parent e5074150a9
commit 4a69c3ae8a
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -58,13 +58,13 @@ def serialize_recipe(urn, recipe_class):
ns = 'no' ns = 'no'
if ns is True: if ns is True:
ns = 'yes' ns = 'yes'
return (' <recipe id="{id}" title={title} author={author} language={language}' return (' <recipe id={id} title={title} author={author} language={language}'
' needs_subscription="{needs_subscription}" description={description}/>').format(**{ ' needs_subscription={needs_subscription} description={description}/>').format(**{
'id' : str(urn), 'id' : quoteattr(str(urn)),
'title' : attr('title', _('Unknown')), 'title' : attr('title', _('Unknown')),
'author' : attr('__author__', default_author), 'author' : attr('__author__', default_author),
'language' : attr('language', 'und'), 'language' : attr('language', 'und'),
'needs_subscription' : ns, 'needs_subscription' : quoteattr(ns),
'description' : attr('description', '') 'description' : attr('description', '')
}) })