diff --git a/boards/mdx_neboard.py b/boards/mdx_neboard.py --- a/boards/mdx_neboard.py +++ b/boards/mdx_neboard.py @@ -26,6 +26,8 @@ ONE_NEWLINE = '\n' REGEX_URL = re.compile(r'https?\://[a-zA-Z0-9\-\.]+\.[a-zA-Z]{2,3}(/\S*)?') LINE_BREAK_HTML = '
' SPOILER_SPACE = ' ' +REGEX_ANY_LINE_BREAK = re.compile(r'(' + LINE_BREAK_HTML + '|\r|\n)') +QUOTE_REPLACEMENT = '\g<1>>' MAX_SPOILER_MULTIPLIER = 2 MAX_SPOILER_SPACE_COUNT = 20 @@ -167,19 +169,14 @@ def render_reflink(tag_name, value, opti def render_quote(tag_name, value, options, parent, context): - source = '' - if 'source' in options: - source = options['source'] - elif 'quote' in options: - source = options['quote'] + source = options.get('quote') or options.get('source') if source: result = '